home *** CD-ROM | disk | FTP | other *** search
/ Magnum One / Magnum One (Mid-American Digital) (Disc Manufacturing).iso / d1 / inter489.arc / INTERRUP.A < prev    next >
Text File  |  1989-07-23  |  296KB  |  8,084 lines

  1. Please redistribute the following files unmodified as a group, in an archive
  2. named INTER489:
  3.     INTERRUP.1ST    the read-me file, containing credits, availability info
  4.     INTERRUP.A    INT 00 through INT 27 \ total 223 pages at 60 lines
  5.     INTERRUP.B    INT 28 through INT FF / per page, 241 with INTPRINT -p
  6.     INTERRUP.PRI    a brief introduction to interrupts
  7.     INTPRINT.COM    a simple formatter that also generates the list summary
  8.     INTPRINT.DOC    instructions for INTPRINT
  9.     INTPRINT.C    source code for INTPRINT
  10. ---------------------------------------------
  11. Release 89.4    Last change 7/22/89
  12. ---------------------------------------------
  13. If you notice any mistakes or omissions, please let me know!  It is only with
  14. YOUR help that the list can continue to grow at the current rate.
  15.  
  16. Please read the file INTERRUP.1ST before asking me any questions.  You may find
  17. that it's already been addressed.
  18.  
  19.      Ralf Brown
  20.  
  21. ARPA: ralf@cs.cmu.edu             \
  22. UUCP: {ucbvax,harvard}!cs.cmu.edu!ralf      > preferred
  23. BIT:  ralf%cs.cmu.edu@cmuccvb         /
  24. FIDO: Ralf Brown 1:129/46 (new address!)
  25.     or post a message to the DR_DEBUG echo
  26.  
  27. I reply to all submissions and inquiries, but some of my replies bounce because
  28. of bad return paths.  If you don't get a response from me within a reasonable
  29. period of time, send it again with a better return path (starting at harvard or
  30. ucbvax for UUCP, from the ARPA Internet for others).
  31. ---------------------------------------------
  32. See INTERRUP.1ST for the key to system abbreviations and a list of the
  33. trademarks mentioned here.
  34. ---------------------------------------------
  35. DISCLAIMER:  I verify the information contained in this list to the best of my
  36. ability, but I cannot be held responsible for any problems caused by use or
  37. misuse of the information, especially for those functions not officially 
  38. documented.  If it is marked "internal", you should check it carefully to make
  39. sure it works the same way in your version of the software (and please let me
  40. know whether or not it works the same way).  Information marked with "???" is
  41. known to be incomplete or guesswork.
  42. ---------------------------------------------
  43. The use of -> instead of = signifies that the indicated register or register
  44. pair contains a pointer to the specified item, rather than the item itself
  45. ---------------------------------------------
  46. INT 00 - internal hardware - DIVIDE ERROR
  47.    Automatically called at end of DIV or IDIV operation that results in error
  48.    or overflow.   Normally set by DOS to display an error message and abort
  49.    the program.
  50. Note: on an 8086/8088, the return address points to the following instruction
  51.       on an 80286/80386, the return address points to the divide instruction
  52. ---------------------------------------------
  53. INT 01 - internal hardware - SINGLE-STEP
  54.    Generated at end of each machine instruction if TF bit in FLAGS is set.
  55.    This is what makes the T command of DEBUG work for single-stepping.    It is
  56.    not generated after MOV to segment register or POP of segment register
  57.    (unless you have a very early 8088 with a microcode bug).
  58. ---------------------------------------------
  59. INT 01 - internal hardware - DEBUGGING EXCEPTIONS (80386)
  60.    Instruction address breakpoint fault - will return to execute instruction
  61.    Data address breakpoint trap - will return to following instruction
  62.    General detect fault, debug registers in use
  63.    Task-switch breakpoint trap
  64. ---------------------------------------------
  65. INT 02 - external hardware - NMI (NON-MASKABLE INTERRUPT)
  66.    Generated by NMI signal in hardware.  This signal has various uses:
  67.  
  68.    Breakout switch on hardware debuggers
  69.    Parity error: all except Jr and CONV
  70.    Coprocessor interrupt: all except Jr and CONV
  71.    Keyboard interrupt: Jr, CONV
  72.    I/O channel check: CONV, PS50+
  73.    Disk-controller power-on request: CONV
  74.    System suspend: CONV
  75.    Real-time clock: CONV
  76.    System watch-dog timer, time-out interrupt: PS50+
  77.    DMA timer time-out interrupt: PS50+
  78. ---------------------------------------------
  79. INT 03 - ONE-BYTE INTERRUPT
  80.    Generated by opcode CCh.  Generally used to set breakpoints for debuggers.
  81.    Also used by Turbo Pascal versions 1,2,3 when {$U+} specified
  82. ---------------------------------------------
  83. INT 04 - internal hardware - OVERFLOW
  84.    Generated by INTO instruction if OF flag is set.  If flag is not set, INTO
  85.    is effectively a NOP.  Used to trap any arithmetic errors before the
  86.    erroneous results propagate further through the computation.
  87. ---------------------------------------------
  88. INT 05 - PRINT-SCREEN KEY
  89.    Automatically called by keyboard scanner when print-screen key is pressed.
  90.    Normally executes routine to print the screen, but may call any routine that
  91.    can safely be executed from inside the keyboard scanner.  Status and result
  92.    byte for default handler is at address 0050:0000.
  93. ---------------------------------------------
  94. INT 05 - internal hardware - BOUND CHECK FAILED (80186+)
  95.    Generated by BOUND instruction when the value to be tested is less than the
  96.    indicated lower bound or greater than the indicated upper bound.  Returning
  97.    from this interrupt re-executes the failing BOUND instruction.
  98. ---------------------------------------------
  99. INT 06 - internal hardware - UNDEFINED OPCODE (80286+)
  100. ---------------------------------------------
  101. INT 07 - internal hardware - NO MATH UNIT AVAILABLE (80286+)
  102.    Can be used to emulate a numeric coprocessor in software
  103. ---------------------------------------------
  104. INT 08 - IRQ0 - TIMER INTERRUPT
  105.    Generated 18.2 times per second, this interrupt is used to keep the
  106.    time-of-day clock updated.
  107. ---------------------------------------------
  108. INT 08 - internal hardware - DOUBLE FAULT (80286+ protected mode)
  109.    Called when multiple exceptions occur on one instruction, or an exception
  110.    occurs in an exception handler.  If an exception occurs in the double fault
  111.    handler, the CPU goes into SHUTDOWN mode (which circuitry in the PC/AT
  112.    converts to a reset).
  113. ---------------------------------------------
  114. INT 09 - IRQ1 - KEYBOARD INTERRUPT
  115.    Generated when data is received from the keyboard.  This is normally a scan
  116.    code, but may also be an ACK or NAK of a command on AT-class keyboards.
  117. ---------------------------------------------
  118. INT 09 - internal hardware - MATH UNIT PROTECTION FAULT (80286+ protected mode)
  119. ---------------------------------------------
  120. INT 0A - IRQ2 - EGA VERTICAL RETRACE
  121. Notes: on the Tandy 1000, this interrupt is used by the hard disk
  122.        the TOPS and PCnet adapters use this interrupt request line by default
  123. ---------------------------------------------
  124. INT 0A - internal hardware - INVALID TASK STATE SEGMENT (80286+ protected-mode)
  125. ---------------------------------------------
  126. INT 0B - IRQ3 - COM2 INTERRUPT
  127. Note:  the TOPS and PCnet adapters use this interrupt request line as an
  128.        alternate
  129. Note:  on PS/2's, COM2 through COM8 share this interrupt
  130.        on many PC's, COM4 shares this interrupt
  131. ---------------------------------------------
  132. INT 0B - internal hardware - NOT PRESENT (80286+ protected-mode)
  133.    Generated when loading a segment register if the segment descriptor
  134.    indicates that the segment is not currently in memory.  May be used to
  135.    implement virtual memory.
  136. ---------------------------------------------
  137. INT 0C - IRQ4 - COM1 INTERRUPT
  138. Note: on many PC's, COM3 shares this interrupt
  139. ---------------------------------------------
  140. INT 0C - internal hardware - STACK FAULT (80286+)
  141.    Generated on stack overflow/underflow in protected mode.
  142.    Note that the 80286 will shut down in real mode if SP=1 before a push.  On
  143.    the PC AT and compatibles, external circuitry generates a reset on shutdown.
  144. ---------------------------------------------
  145. INT 0D - IRQ5 - FIXED DISK (PC), LPT2 (AT/PS)
  146. Note: the Tandy 1000 uses this line for the 60Hhz RAM refresh
  147. ---------------------------------------------
  148. INT 0D - internal hardware - GENERAL PROTECTION VIOLATION (80286+)
  149.    Called in real mode when an instruction attempts to access a word operand
  150.    located at offset FFFFh or a PUSH MEM or POP MEM instruction contains an
  151.    invalid bit encoding in the second byte, or an instruction exceeds the
  152.    maximum length allowed (10 bytes for 80286, 15 bytes for 80386)
  153. ---------------------------------------------
  154. INT 0E - IRQ6 - DISKETTE INTERRUPT
  155.    Generated by floppy disk controller on completion of an operation
  156. ---------------------------------------------
  157. INT 0E - internal hardware - PAGE FAULT (80386 native mode)
  158.    used to implement virtual memory
  159. ---------------------------------------------
  160. INT 0F - IRQ7 - PRINTER INTERRUPT
  161.    Generated by the LPT1 printer adapter when printer becomes ready.
  162. Note: most printer adapters do not reliably generate this interrupt.
  163. ---------------------------------------------
  164. INT 10 - internal hardware - COPROCESSOR ERROR (80286+)
  165.    Generated by the CPU when the -ERROR pin is asserted by the coprocessor.
  166.    AT's and clones usually wire the coprocessor to use IRQ13, but not all
  167.    get it right.
  168. ---------------------------------------------
  169. INT 10 - VIDEO - SET VIDEO MODE
  170.     AH = 00h
  171.     AL = mode (graphics mode if graphics resolution listed)
  172.          text  pixel graphic colors disp scrn  system
  173.          resol    box  resoltn        page addr
  174.        00h = 40x25    8x8         B&W      8     B800 CGA
  175.            = 40x25    8x14         B&W      8     B800 ATI VIP
  176.        01h = 40x25    8x8          16      8     B800 CGA
  177.            = 40x25    8x14          16      8     B800 ATI VIP
  178.        02h = 80x25    8x8         B&W      4     B800 CGA
  179.            = 80x25    8x8         B&W      8     B800 EGA,MCGA,VGA
  180.            = 80x25    8x14         B&W      8     B800 ATI VIP
  181.        03h = 80x25    8x8          16      4     B800 CGA
  182.            = 80x25    8x8          16      8     B800 EGA,MCGA,VGA
  183.        04h = 40x25    8x8  320x200   4      1     B800 CGA
  184.        05h = 40x25    8x8  320x200 4 gray   1     B800 CGA
  185.        06h = 80x25    8x8  640x200 B&W      1     B800 CGA
  186.        07h = 80x25    9x14         mono     1     B000 MDA,Hercules
  187.            = 80x25                  8          EGA,VGA
  188.            = 80x25    9x14         mono     B000 ATI VIP
  189.        08h = 20x25    8x8  160x200  16     B800 PCjr,Tandy 1000
  190.        09h = 40x25    8x8  320x200  16     B800 PCjr,Tandy 1000
  191.        0Ah = 80x25    8x8  640x200   4     B800 PCjr,Tandy 1000
  192.        0Bh = reserved (used internally by EGA BIOS)
  193.        0Ch = reserved (used internally by EGA BIOS)
  194.        0Dh = 40x25    8x8  320x200  16      8     A000 EGA,VGA
  195.        0Eh = 80x25    8x8  640x200  16      4     A000 EGA,VGA
  196.        0Fh = 80x25    8x14 640x350 mono     2     A000 EGA,VGA
  197.        10h = 80x25    8x14 640x350 4or16    2     A000 EGA,VGA
  198.        11h = 80x30    8x16 640x480 mono     A000 VGA,MCGA,ATI EGA,ATI VIP
  199.        12h = 80x30    8x16 640x480 16/256k     A000 VGA,ATI VIP
  200.            = 80x30    8x16 640x480 16/64     A000 ATI EGA Wonder
  201.        13h = 40x25    8x8  320x200 256/256k     A000 VGA,MCGA,ATI VIP
  202.        14h = 80x25    8x8  640x200              Lava Chrome II EGA
  203.            =         640x400  16          Tecmar VGA/AD
  204.        15h = 80x25    8x14 640x350              Lava Chrome II EGA
  205.        16h = 80x25    8x14 640x350              Lava Chrome II EGA
  206.            =         800x600  16          Tecmar VGA/AD
  207.        17h = 80x34    8x14 640x480              Lava Chrome II EGA
  208.            = 132x25                      Tecmar VGA/AD
  209.        18h = 132x44 8x8         mono          Tseng Labs EVA
  210.            = 80x34    8x14 640x480              Lava Chrome II EGA
  211.            =         1024x768 16          Tecmar VGA/AD
  212.        19h = 132x25 8x14         mono          Tseng Labs EVA
  213.        1Ah = 132x28 8x13         mono          Tseng Labs EVA
  214.            =         640x350 256          Tecmar VGA/AD
  215.        1Bh =         640x400 256          Tecmar VGA/AD
  216.        1Ch =         640x480 256          Tecmar VGA/AD
  217.        1Dh =         800x600 256          Tecmar VGA/AD
  218.        22h = 132x44 8x8                  Tseng Labs EVA
  219.            = 132x44 8x8                  Ahead Systems EGA2001
  220.            = 132x43                      Allstar Peacock (VGA)
  221.        23h = 132x25 6x14                  Tseng Labs EVA
  222.            = 132x25 8x14                  Ahead Systems EGA2001
  223.            = 132x25 8x8          16     B800 ATI EGA Wonder,ATI VIP
  224.            = 132x28                      Allstar Peacock (VGA)
  225.        24h = 132x28 6x13                  Tseng Labs EVA
  226.            = 132x25                      Allstar Peacock (VGA)
  227.        25h = 80x60    8x8  640x480              Tseng Labs EVA
  228.            =         640x480  16          VEGA VGA
  229.        26h = 80x60    8x8                  Tseng Labs EVA
  230.            = 80x60    8x8  640x480              Ahead Systems EGA2001
  231.            = 80x60                      Allstar Peacock (VGA)
  232.        27h =         720x512  16          VEGA VGA
  233.            =             720x512  16          Genoa
  234.            = 132x25 8x8         mono     B800 ATI EGA Wonder,ATI VIP
  235.        28h = ???x???                  VEGA VGA
  236.        29h =         800x600  16          VEGA VGA
  237.            =         800x600  16          Orchid,STB,Genoa,Sigma
  238.            =         800x600  16          Allstar Peacock (VGA)
  239.        2Ah = 100x40                   Allstar Peacock (VGA)
  240.            = 100x40 8x16                  Orchid Prodesigner VGA
  241.        2Dh =         640x350 256          VEGA VGA
  242.            =         640x350 256          Genoa,STB
  243.        2Eh =         640x480 256          VEGA VGA
  244.            =         640x480 256          Orchid,STB,Genoa,Sigma
  245.        2Fh =         720x512 256          VEGA VGA
  246.            =         720x512 256          Genoa
  247.        30h =         800x600 256          VEGA VGA
  248.            =         800x060 256          Orchid,STB,Genoa,Sigma
  249.            =         ???x???         B800 AT&T 6300
  250.        33h = 132x44 8x8          16     B800 ATI EGA Wonder,ATI VIP
  251.        36h =         960x720  16          VEGA VGA
  252.            =         960x720  16          STB
  253.        37h =        1024x768  16          VEGA VGA
  254.            =        1024x768  16          Orchid,STB,Genoa,Sigma
  255.            = 132x44 8x8         mono     B800 ATI EGA Wonder,ATI VIP
  256.        40h = 80x25    8x16 640x400   2      1  B800 AT&T 6300, AT&T VDC600
  257.            = 80x25    8x16 640x400   2      1  B800 Compaq Portable
  258.            = 80x43                      VEGA VGA, Tecmar VGA/AD
  259.            = 80x43                      Video7 V-RAM VGA
  260.            = 80x43                      Tatung VGA
  261.        41h =         640x200  16      1          AT&T 6300
  262.            = 132x25                   VEGA VGA
  263.            = 132x25                      Tatung VGA
  264.            = 132x25                      Video7 V-RAM VGA
  265.        42h = 80x25    8x16 640x400  16          AT&T 6300, AT&T VDC600
  266.            = 132x43                   VEGA VGA
  267.            = 132x43                      Tatung VGA
  268.            = 132x43                      Video7 V-RAM VGA
  269.        43h = unsupported 640x200 of 640x400 viewport  AT&T 6300
  270.            = 80x60                      VEGA VGA
  271.            = 80x60                      Tatung VGA
  272.            = 80x60                      Video7 V-RAM VGA
  273.        44h = disable VDC and DEB output          AT&T 6300
  274.            = 100x60                   VEGA VGA
  275.            = 100x60                   Tatung VGA
  276.            = 100x60                      Video7 V-RAM VGA
  277.        45h = 132x28                      Tatung VGA
  278.            = 132x28                      Video7 V-RAM VGA
  279.        46h = 100x40 8x15 800x600   2          AT&T VDC600
  280.        47h = 100x37 8x16 800x600  16          AT&T VDC600
  281.        48h = 80x50    8x8  640x400   2     B800 AT&T 6300, AT&T VDC600
  282.        49h = 80x30    8x16 640x480              Lava Chrome II EGA
  283.        4Dh = 120x25                   VEGA VGA
  284.        4Eh = 120x43                   VEGA VGA
  285.        4Fh = 132x25                   VEGA VGA
  286.        50h = 132x25 9x14         mono          Ahead Systems EGA2001
  287.            = 80x30    8x16 640x480  16          Paradise EGA-480
  288.            = 80x43             mono          VEGA VGA
  289.            =         640x480 mono???          Taxan 565 EGA
  290.            = 80x34                      Lava Chrome II EGA
  291.        51h = 80x30    8x16                  Paradise EGA-480
  292.            = 80x30                      Lava Chrome II EGA
  293.            = 80x34    8x14 640x480  16          ATI EGA Wonder
  294.            = 132x25          mono          VEGA VGA
  295.        52h = 132x44 9x8         mono          Ahead Systems EGA2001
  296.            = 132x43          mono          VEGA VGA
  297.            = 94x29    8x14 752x410  16          ATI EGA Wonder
  298.            = 80x60                      Lava Chrome II EGA
  299.        53h = 100x40 8x14 800x560  16          ATI EGA Wonder,ATI VIP
  300.            = 132x43                   Lava Chrome II EGA
  301.        54h = 132x43 8x8                  Paradise EGA-480
  302.            = 132x43 7x9         16/256k     B800 Paradise VGA
  303.            = 132x43 8x9         16/256k     B800 Paradise VGA on multisync
  304.            = 132x43                      Taxan 565 EGA
  305.            = 132x43                      AST VGA Plus
  306.            = 132x43                      Hewlett-Packard D1180A
  307.            = 132x43 7x9          16          AT&T VDC600
  308.            = 132x25                   Lava Chrome II EGA
  309.            = 100x42 8x14 800x600  16     A000 ATI EGA Wonder, VGA Wondr
  310.        55h = 132x25 8x14                  Paradise EGA-480
  311.            = 132x25 7x16         16/256k     B800 Paradise VGA
  312.            = 132x25 8x16         16/256k     B800 Paradise VGA on multisync
  313.            = 132x25                      Taxan 565 EGA
  314.            = 132x25                      AST VGA Plus
  315.            = 132x25                      Hewlett-Packard D1180A
  316.            = 132x25 7x16          16          AT&T VDC600
  317.            = 80x66    8x8         16/256k     A000 ATI VIP
  318.            = 94x29    8x14 752x410              Lava Chrome II EGA
  319.        56h = 132x43 8x8         3???     2     B000 NSI Smart EGA+
  320.            = 132x43 7x9           4     B000 Paradise VGA
  321.            = 132x43 8x9           4     B000 Paradisk VGA on multisync
  322.            = 132x43          mono          Taxan 565 EGA
  323.            = 132x43 7x9           2          AT&T VDC600
  324.        57h = 132x25 8x14         3???     4  B000 NSI Smart EGA+
  325.            = 132x25 7x16           4     B000 Paradise VGA
  326.            = 132x25 8x16           4     B000 Paradise VGA on multisync
  327.            = 132x25          mono          Taxan 565 EGA
  328.            = 132x25 7x16           2          AT&T VDC600
  329.        58h = 100x75 8x8  800x600 16/256k     A000 Paradise VGA
  330.            = 100x75 8x8  800x600  16          AT&T VDC600
  331.            = 80x33    8x14          16     B800 ATI EGA Wonder,ATI VIP
  332.            =         800x600  16          AST VGA Plus, Compaq VGA
  333.            =             800x600  16          Dell VGA
  334.            =         800x600  16          Hewlett-Packard D1180A
  335.        59h = 100x75 8x8  800x600   2     A000 Paradise VGA
  336.            = 100x75 8x8  800x600   2          AT&T VDC600
  337.            = 80x66    8x8         16/256k     A000 ATI VIP
  338.            =         800x600   2          AST VGA Plus, Compaq VGA
  339.            =         800x600   2          Dell VGA
  340.            =         800x600   2          Hewlett-Packard D1180A
  341.        5Eh =         640x400 256          Paradise VGA,VEGA VGA
  342.            =         640x400 256          AST VGA Plus
  343.            =         640x400 256          Compaq VGA, Dell VGA
  344.            = 80x25    8x16 640x400 256          AT&T VDC600
  345.        5Fh =         640x480 256          Paradise VGA
  346.            =         640x480 256          AST VGA Plus
  347.            =         640x480 256          Compaq VGA, Dell VGA
  348.            =         640x480 256          Hewlett-Packard D1180A
  349.            = 80x30    8x16 640x480 256          AT&T VDC600 (512K)
  350.        60h = 80x???      ???x400              Corona/Cordata BIOS 4.10+
  351.            =         752x410              VEGA VGA
  352.            =         752x410  16          Tatung VGA
  353.            =         752x410  16          Video7 V-RAM VGA
  354.        61h =         ???x400              Corona/Cordata BIOS 4.10+
  355.            =         720x540              VEGA VGA
  356.            =         720x540  16          Tatung VGA
  357.            =         720x540  16          Video7 V-RAM VGA
  358.            =         640x400 256     A000 ATI VGA Wonder
  359.        62h =         800x600              VEGA VGA
  360.            =         800x600  16          Tatung VGA
  361.            =         800x600  16          Video7 V-RAM VGA
  362.            =         640x480 256     A000 ATI VGA Wonder
  363.        63h =        1024x768   2          Video7 V-RAM VGA
  364.            =         800x600 256     A000 ATI VGA Wonder
  365.        64h =        1024x768   4          Video7 V-RAM VGA
  366.        65h =        1024x768  16          Video7 V-RAM VGA
  367.            =        1024x768  16     A000 ATI VGA Wonder
  368.        66h =         640x400 256          Tatung VGA
  369.            =         640x400 256          Video7 V-RAM VGA
  370.        67h =         640x480 256          Video7 V-RAM VGA
  371.            =        1024x768   4     A000 ATI VGA Wonder
  372.        69h =         720x540 256          Video7 V-RAM VGA
  373.        6Ah =         800x600  16          VESA standard interface
  374.        70h = extended mode set (see AX=0070h)     Everex Micro Enhancer EGA
  375.        71h = 100x35 8x16 800x600 16of64     A000 NSI Smart EGA+
  376.        74h =         640x400   2     B800 Toshiba 3100 AT&T mode
  377.        7Ch =             512x512  16          Genoa
  378.        7Dh =         512x512 256          Genoa
  379.        7Eh = special mode set (see AX=007Eh)      Paradise VGA, AT&T VDC600
  380.        7Fh = special function set (see AX=007Fh)  Paradise VGA, AT&T VDC600
  381.        82h = 80x25             B&W          AT&T VDC overlay mode *
  382.        83h = 80x25                      AT&T VDC overlay mode *
  383.        86h =         640x200 B&W          AT&T VDC overlay mode *
  384.        C0h =         640x400   2/prog pallet  AT&T VDC overlay mode *
  385.        C4h = disable output               AT&T VDC overlay mode *
  386.        D0h =         640x400   2     B800 DEC VAXmate AT&T mode
  387.        ??? =         640x225              Z-100
  388.        ??? =         640x400              Z-100
  389.  
  390.  * for AT&T VDC overlay modes, BL contains the DEB mode, which may be 06h,
  391.       40h, or 44h
  392. Note: IBM standard modes do not clear the screen if the high bit of AL is set
  393. ---------------------------------------------
  394. INT 10 - VIDEO - Everex Micro Enhancer EGA - EXTENDED MODE SET
  395.     AX = 0070h
  396.     BL = mode (graphics mode if graphics resolution listed)
  397.          text  pixel graphic color disp scrn  monitor
  398.          resol    box  resoltn       page addr
  399.        00h =         640x480  16          multisync'ing
  400.        01h =         752x410  16          multisync'ing
  401.        02h =             800x600  16          multisync'ing
  402.        03h = 80x34                      multisync'ing
  403.        04h = 80x60                      multisync'ing
  404.        05h = 94x29                      multisync'ing
  405.        06h = 94x51                      multisync'ing
  406.        07h = reserved
  407.        08h = reserved
  408.        09h = 80x44                      EGA
  409.        0Ah = 132x25                   EGA
  410.        0Bh = 132x44                   EGA
  411.        0Ch = 132x25                   CGA
  412.        0Dh = 80x44                      mono
  413.        0Eh = 132x25                   mono
  414.        0Fh = 132x44                   mono
  415.        10h = reserved
  416.        11h =            1280x350   4
  417.        12h =        1280x600   4
  418.        13h =             640x350 256
  419.        14h =         640x400 256
  420.        15h =         512x480 256
  421. ---------------------------------------------
  422. INT 10 - VIDEO - Paradise VGA, AT&T VDC600 - SET SPECIAL MODE
  423.     AX = 007Eh
  424.     BX = The horizontal dimension of the mode desired
  425.     CX = The vertical dimension of the mode desired
  426.          (both BX/CX in pixels for graphics modes, rows for alpha modes)
  427.     DX = The number of colors of the mode desired
  428.          (use 0 for monochrome modes)
  429. Return: BH = 7Eh if successful (Paradise VGA)
  430.     AL = 7Eh if successful (AT&T VDC600)
  431. ---------------------------------------------
  432. INT 10 - VIDEO - Paradise VGA, AT&T VDC600 - EXTENDED FUNCTIONS
  433.     AX = 007Fh
  434.     BH = 00h  set VGA operation
  435.     BH = 01h  set non-VGA operation
  436.         color modes (0,1,2,3,4,5,6) will set non-VGA CGA operation.
  437.         monochrome mode 7 will set non-VGA MDA/Hercules operation.
  438.     BH = 02h  query mode status
  439.         Return: BL = 00h if operating in VGA mode, 01h if non-VGA mode.
  440.             CH = total video RAM size in 64k byte units.
  441.             CL = video RAM used by the current mode.
  442.     BH = 03h  lock current mode
  443.         allows current mode (VGA or non-VGA) to survive re-boot.
  444.     BH = 04h  enter CGA mode (AT&T VDC600 only)
  445.     BH = 05h  enter MDA mode (AT&T VDC600 only)
  446.     BH = 0Ah,0Bh,0Ch,0Dh,0Eh,0Fh  WRITE PARADISE REGISTERS 0,1,2,3,4,5
  447.         (port 03CEh indices 0Ah,0Bh,0Ch,0Dh,0Eh,0Fh)
  448.         BL = value to set in the paradise register.
  449.     BH = 1Ah,1Bh,1Ch,1Dh,1Eh,1Fh READ PARADISE REGISTERS 0,1,2,3,4,5
  450.         (port 03CEh indices 0Ah,0Bh,0Ch,0Dh,0Eh,0Fh)
  451.         Return: BL = value of the paradise register.
  452.             BH = 7Fh if successful.
  453. Return: AL = 7Fh if successful (AT&T VDC600)
  454. ---------------------------------------------
  455. INT 10 - VIDEO - SET CURSOR CHARACTERISTICS
  456.     AH = 01h
  457.     CH bits 0-4 = start line for cursor in character cell
  458.        bits 5-6 = blink attribute
  459.              (00=normal, 01=invisible, 10=slow, 11=fast)
  460.     CL bits 0-4 = end line for cursor in character cell
  461. Note: buggy on EGA systems--BIOS remaps cursor shape in 43 line modes, but
  462.       returns unmapped cursor shape
  463. ---------------------------------------------
  464. INT 10 - VIDEO - SET CURSOR POSITION
  465.     AH = 02h
  466.     DH,DL = row, column (0,0 = upper left)
  467.     BH = page number
  468.         0 in graphics modes
  469.         0-3 in modes 2&3
  470.         0-7 in modes 0&1
  471. ---------------------------------------------
  472. INT 10 - VIDEO - READ CURSOR POSITION
  473.     AH = 03h
  474.     BH = page number
  475.         0 in graphics modes
  476.         0-3 in modes 2&3
  477.         0-7 in modes 0&1
  478. Return: DH,DL = row,column
  479.     CH = cursor start line
  480.     CL = cursor end line
  481. ---------------------------------------------
  482. INT 10 - VIDEO - READ LIGHT PEN POSITION (all but PS)
  483.     AH = 04h
  484. Return: AH = 00h light pen switch not activated
  485.        = 01h light pen values in registers
  486.         DH,DL = row,column of current position
  487.         CH = raster line (0-199) (EGA) old graphics modes
  488.         CX = (EGA) raster line (0-nnn) new graphics modes
  489.         BX = pixel column (0-319 or 0-639)
  490. ---------------------------------------------
  491. INT 10 - VIDEO - SELECT DISPLAY PAGE
  492.     AH = 05h
  493.     AL = display page
  494.         0-7  for modes 0 & 1
  495.         0-3  for modes 2 & 3
  496. ---------------------------------------------
  497. INT 10 - PCjr VIDEO - CRT/CPU PAGE REGISTERS
  498.     AH = 05h
  499.     AL =
  500.         80h read CRT/CPU page registers
  501.         81h set CPU page register
  502.         BL = new page register value
  503.         82h set CRT page register
  504.         BH = new page register value
  505.         83h set both display registers
  506.         BL = new CPU page register
  507.         BH = new CRT page register
  508. Return: BH = CRT page register
  509.     BL = CPU page register
  510. ---------------------------------------------
  511. INT 10 - VIDEO - GRAPHICS BITMAP BUFFER (Corona/Cordata BIOS v4.10+)
  512.     AH = 05h
  513.     AL =
  514.         00h set address of graphics bitmap buffer (video modes 60h,61h)
  515.         BX = segment of buffer
  516.         0Fh get address of graphics bitmap buffer (video modes 60h,61h)
  517.         Return: DX = segment of graphics bitmap buffer
  518. ---------------------------------------------
  519. INT 10 - VIDEO - SCROLL PAGE UP
  520.     AH = 06h
  521.     AL = number of lines to scroll window (0 = blank whole window)
  522.     BH = attributes to be used on blanked lines
  523.     CH,CL = row,column of upper left corner of window to scroll
  524.     DH,DL = row,column of lower right corner of window
  525. ---------------------------------------------
  526. INT 10 - VIDEO - SCROLL PAGE DOWN
  527.     AH = 07h
  528.     AL = number of lines to scroll window (0 = blank whole window)
  529.     BH = attributes to be used on blanked lines
  530.     CH,CL = row,column of upper left corner of window to scroll
  531.     DH,DL = row,column of lower right corner of window
  532. ---------------------------------------------
  533. INT 10 - VIDEO - READ ATTRIBUTES/CHARACTER AT CURSOR POSITION
  534.     AH = 08h
  535.     BH = display page
  536. Return: AL = character
  537.     AH = attribute of character (alpha modes)
  538. ---------------------------------------------
  539. INT 10 - VIDEO - WRITE ATTRIBUTES/CHARACTERS AT CURSOR POSITION
  540.     AH = 09h
  541.     AL = character
  542.     BH = display page
  543.     BL = attributes of character (alpha modes) or color (graphics modes)
  544.          if bit 7 set in graphics mode, character is xor'ed onto screen
  545.     CX = number of times to write character
  546. Note: all characters are displayed, including CR, LF, and BS
  547. ---------------------------------------------
  548. INT 10 - VIDEO - WRITE CHARACTERS ONLY AT CURSOR POSITION
  549.     AH = 0Ah
  550.     AL = character
  551.     BH = display page - alpha mode
  552.     BL = color of character (graphics mode, PCjr only)
  553.          if bit 7 set in graphics mode, character is xor'ed onto screen
  554.     CX = number of times to write character
  555.          (EGA) in graphics modes, replication count in CX works correctly
  556.          only if all character written are contains on the same row
  557. Note: all characters are displayed, including CR, LF, and BS
  558. ---------------------------------------------
  559. INT 10 - VIDEO - SET COLOR PALETTE
  560.     AH = 0Bh
  561.     BH = 00h
  562.         BL = border color (0-15) (text modes)
  563.          border color and background color (graphics modes)
  564.         (EGA)
  565.         BL = border color (0-15) and high-intensity background color
  566.           (16-31??? maybe should be high nybble?)
  567.     BH = 01h
  568.         BL = palette (0-3)
  569. ---------------------------------------------
  570. INT 10 - VIDEO - WRITE DOT ON SCREEN
  571.     AH = 0Ch
  572.     AL = color of dot (0/1 in mode 6, 0-3 in modes 4 and 5)
  573.          if bit 7 set, new color will be XORed with current pixel
  574.     BH = display page (ignored if mode only supports one page)
  575.     CX = column
  576.     DX = row
  577. Note: only valid in graphics modes
  578. ---------------------------------------------
  579. INT 10 - VIDEO - READ DOT ON SCREEN
  580.     AH = 0Dh
  581.     BH = display page (ignored if mode only supports one page)
  582.     CX = column
  583.     DX = row
  584. Return: AL = color read
  585. Note: only valid in graphics modes
  586. ---------------------------------------------
  587. INT 10 - VIDEO - WRITE CHARACTER AND ADVANCE CURSOR (TTY WRITE)
  588.     AH = 0Eh
  589.     AL = character
  590.     BH = display page (alpha modes)
  591.     BL = foreground color (graphics modes)
  592. Note: characters 07h (BEL), 08h (BS), 0Ah (LF), and 0Dh (CR) are interpreted
  593.       and do the expected things
  594. ---------------------------------------------
  595. INT 10 - VIDEO - GET CURRENT VIDEO MODE
  596.     AH = 0Fh
  597. Return: AH = number of columns on screen
  598.     AL = current video mode (see INT 10/AH=00h)
  599.     BH = current active display page
  600. Note:    if mode was set with bit 7 set ("no blanking"), the returned mode will
  601.     also have bit 7 set
  602. ---------------------------------------------
  603. INT 10 - VIDEO - SET PALETTE REGISTER (Jr, PS, TANDY 1000, EGA, VGA)
  604.     AX = 1000h
  605.     BL = palette register to set
  606.     BH = color value to store
  607. Note: on MCGA, only BX = 0712h is supported
  608. ---------------------------------------------
  609. INT 10 - VIDEO - SET BORDER COLOR REGISTER (Jr, PS, TANDY 1000, EGA, VGA)
  610.     AX = 1001h
  611.     BH = color value to store
  612. ---------------------------------------------
  613. INT 10 - VIDEO - SET ALL PALETTE REGISTERS (Jr, PS, TANDY 1000, EGA, VGA)
  614.     AX = 1002h
  615.     ES:DX -> 17-byte palette register list (see below)
  616.  
  617. Format of palette register list:
  618. Offset    Size    Description
  619.  00h 16 BYTEs    values for palette registers 0-15
  620.  10h    BYTE    value for border color register
  621. ---------------------------------------------
  622. INT 10 - VIDEO - TOGGLE INTENSITY/BLINKING BIT (Jr, PS, TANDY 1000, EGA, VGA)
  623.     AX = 1003h
  624.     BL = 00h enable intensity
  625.        = 01h enable blink
  626. ---------------------------------------------
  627. INT 10 - VIDEO - GET INDIVIDUAL PALETTE REGISTER (VGA)
  628.     AX = 1007h
  629.     BL = palette register number
  630. Return: BH = palette register value
  631. ---------------------------------------------
  632. INT 10 - VIDEO - READ OVERSCAN (BORDER COLOR) REGISTER (VGA)
  633.     AX = 1008h
  634. Return: BH = value
  635. ---------------------------------------------
  636. INT 10 - VIDEO - READ ALL PALETTE REGISTERS AND OVERSCAN REGISTER (VGA)
  637.     AX = 1009h
  638.     ES:DX -> 17-byte buffer (see AX=1002h)
  639. ---------------------------------------------
  640. INT 10 - VIDEO - SET INDIVIDUAL DAC REGISTER (EGA, VGA/MCGA)
  641.     AX = 1010h
  642.     BX = register number
  643.     CH = new value for green (0-63)
  644.     CL = new value for blue (0-63)
  645.     DH = new value for red (0-63)
  646. ---------------------------------------------
  647. INT 10 - VIDEO - SET BLOCK OF DAC REGISTERS (EGA, VGA/MCGA)
  648.     AX = 1012h
  649.     BX = starting color register
  650.     CX = number of registers to set
  651.     ES:DX -> table of 3*CX bytes where each 3 byte group represents one
  652.          byte each of red, green and blue (0-63)
  653. ---------------------------------------------
  654. INT 10 - VIDEO - SELECT VIDEO DAC COLOR PAGE (VGA)
  655.     AX = 1013h
  656.     BL = 00h Select paging mode
  657.         BH = 00h Select 4 blocks of 64
  658.         BH = 01h Select 16 blocks of 16
  659.     BL = 01h Select Page
  660.         BH = page number (00h to 03h) or (00h to 0Fh)
  661. Note: not valid in mode 13h
  662. ---------------------------------------------
  663. INT 10 - VIDEO - READ INDIVIDUAL DAC REGISTER (EGA, VGA/MCGA)
  664.     AX = 1015h
  665.     BL = palette register number
  666. Return: DH = red value
  667.     CH = green value
  668.     CL = blue value
  669. ---------------------------------------------
  670. INT 10 - VIDEO - READ BLOCK OF DAC REGISTERS (EGA, VGA/MCGA)
  671.     AX = 1017h
  672.     BX = starting palette register
  673.     CX = number of palette registers to read
  674.     ES:DX -> buffer (3 * CX bytes in size) (see also AX=1012h)
  675. Return: CX number of red, green and blue triples in buffer
  676. ---------------------------------------------
  677. INT 10 - VIDEO - undocumented - SET PEL MASK (EGA, VGA/MCGA)
  678.     AX = 1018h
  679.     BL = new PEL value
  680. ---------------------------------------------
  681. INT 10 - VIDEO - undocumented - READ PEL MASK (EGA, VGA/MCGA)
  682.     AX = 1019h
  683. Return:    BL = value read
  684. ---------------------------------------------
  685. INT 10 - VIDEO - GET VIDEO DAC COLOR-PAGE STATE (VGA)
  686.     AX = 101Ah
  687. Return: BL = paging mode
  688.         00h four pages of 64
  689.         01h sixteen pages of 16
  690.     BH = current page
  691. ---------------------------------------------
  692. INT 10 - VIDEO - PERFORM GRAY-SCALE SUMMING (EGA, VGA/MCGA)
  693.     AX = 101Bh
  694.     BX = starting palette register
  695.     CX = number of registers to convert
  696. ---------------------------------------------
  697. INT 10 - VIDEO - TEXT-MODE CHARACTER GENERATOR FUNCTIONS (PS, EGA, VGA)
  698.     AH = 11h
  699.     The following functions will cause a mode set, completely resetting
  700.     the video environment, but without clearing the video buffer
  701.     AL = 00h, 10h: load user-specified patterns
  702.         ES:BP -> user table
  703.         CX      = count of patterns to store
  704.         DX      = character offset into map 2 block
  705.         BL      = block to load in map 2
  706.         BH      = number of bytes per character pattern
  707.     AL = 01h, 11h: load ROM monochrome patterns (8 by 14)
  708.         BL      = block to load
  709.     AL = 02h, 12h: load ROM 8 by 8 double-dot patterns
  710.         BL      = block to load
  711.     AL = 03h: set block specifier
  712.         BL      = block specifier
  713.            (EGA/MCGA) bits 0,1 = block selected by chars with attribute
  714.                      bit 3 = 0
  715.                   bits 2,3 = block selected by chars with attribute
  716.                      bit 3 = 1
  717.            (VGA) bits 0,1,4 = block selected by attribute bit 3 = 0
  718.              bits 2,3,5 = block selected by attribute bit 3 = 1
  719.     AL = 04h, 14h: load ROM 8x16 character set (VGA)
  720.     The routines called with AL=1xh are designed to be called only
  721.     immediately after a mode set and are similar to the routines called
  722.     with AL=0xh, except that:
  723.           Page 0 must be active.
  724.           Bytes/character is recalculated.
  725.           Max character rows is recalculated.
  726.           CRT buffer length is recalculated.
  727.           CRTC registers are reprogrammed as follows:
  728.              R09 = bytes/char-1 ; max scan line (mode 7 only)
  729.              R0A = bytes/char-2 ; cursor start
  730.              R0B = 0        ; cursor end
  731.              R12 = ((rows+1)*(bytes/char))-1 ; vertical display end
  732.              R14 = bytes/char    ; underline loc
  733.                (*** BUG: should be 1 less ***)
  734. ---------------------------------------------
  735. INT 10 - VIDEO - GRAPHICS-MODE CHARACTER GENERATOR FUNCTIONS (PS, EGA, VGA)
  736.     AH = 11h
  737.     AL = 20h: set user 8 by 8 graphics characters (INT 1Fh)
  738.         ES:BP -> user table
  739.     AL = 21h: set user graphics characters
  740.         ES:BP -> user table
  741.         CX      = bytes per character
  742.         BL      = row specifier
  743.            00h user set
  744.               DL = number of rows
  745.            01h 14 rows
  746.            02h 25 rows
  747.            03h 43 rows
  748.     AL = 22h: ROM 8 by 14 set
  749.         BL = row specifier
  750.     AL = 23h: ROM 8 by 8 double dot
  751.         BL = row specifier
  752.     AL = 24h: load 8x16 graphics characters (VGA/MCGA)
  753.         BL = row specifier
  754. Note: these functions are meant to be called only after a mode set
  755. ---------------------------------------------
  756. INT 10 - VIDEO - GET FONT INFORMATION (EGA, MCGA, VGA)
  757.     AX = 1130h
  758.     BH = pointer specifier
  759.         00h INT 1Fh pointer
  760.         01h INT 44h pointer
  761.         02h ROM 8 by 14 character font pointer
  762.         03h ROM 8 by 8 double dot font pointer
  763.         04h ROM 8 by 8 DD font (top half)
  764.         05h ROM alpha alternate (9 by 14) pointer
  765. Return: ES:BP = specified pointer
  766.     CX    = bytes/character
  767.     DL    = character rows on screen
  768. ---------------------------------------------
  769. INT 10 - VIDEO - ALTERNATE FUNCTION SELECT (PS, EGA, VGA, MCGA) - GET EGA INFO
  770.     AH = 12h
  771.     BL = 10h
  772. Return: BH = 00h color mode in effect (I/O port 3Dxh)
  773.            01h mono mode in effect (I/O port 3Bxh)
  774.     BL = 00h  64k bytes memory installed
  775.          01h 128k bytes memory installed
  776.          02h 192k bytes memory installed
  777.          03h 256k bytes memory installed
  778.     CH = feature bits
  779.     CL = switch settings
  780. ---------------------------------------------
  781. INT 10 - VIDEO - ALTERNATE FUNCTION SELECT (PS,EGA,VGA,MCGA) - ALTERNATE PRTSC
  782.     AH = 12h
  783.     BL = 20h  select alternate print screen routine
  784. ---------------------------------------------
  785. INT 10 - VIDEO - ALTERNATE FUNCTION SELECT (VGA) - SELECT VERTICAL RESOLUTION
  786.     AH = 12h
  787.     BL = 30h
  788.     AL = vertical resolution
  789.          00h 200 scan lines
  790.          01h 350 scan lines
  791.          02h 400 scan lines
  792. Return: AL = 12h if function supported
  793. ---------------------------------------------
  794. INT 10 - VIDEO - ALTERNATE FUNCTION SELECT (VGA, MCGA) - PALETTE LOADING
  795.     AH = 12h
  796.     BL = 31h
  797.     AL = 00h enable default palette loading
  798.          01h disable default palette loading
  799. Return: AL = 12h if function supported
  800. ---------------------------------------------
  801. INT 10 - VIDEO - ALTERNATE FUNCTION SELECT (VGA, MCGA) - VIDEO ADDRESSING
  802.     AH = 12h
  803.     BL = 32h
  804.     AL = 00h enable video addressing
  805.          01h disable video addressing
  806. Return: AL = 12h if function supported
  807. ---------------------------------------------
  808. INT 10 - VIDEO - ALTERNATE FUNCTION SELECT (VGA, MCGA) - GRAY-SCALE SUMMING
  809.     AH = 12h
  810.     BL = 33h
  811.     AL = 00h enable gray scale summing
  812.          01h disable gray scale summing
  813. Return: AL = 12h if function supported
  814. ---------------------------------------------
  815. INT 10 - VIDEO - ALTERNATE FUNCTION SELECT (VGA) - CURSOR EMULATION
  816.     AH = 12h
  817.     BL = 34h
  818.     AL = 00h enable alphanumeric cursor emulation
  819.          01h disable alphanumeric cursor emulation
  820. Return: AL = 12h if function supported
  821. ---------------------------------------------
  822. INT 10 - VIDEO - ALTERNATE FUNCTION SELECT (PS) - DISPLAY-SWITCH INTERFACE
  823.     AH = 12h
  824.     BL = 35h
  825.     AL = 00h initial adapter video off
  826.          01h initial planar video on
  827.          02h switch active video off
  828.          03h switch inactive video on
  829.          80h *UNDOCUMENTED* set system board video active flag
  830.     ES:DX = buffer (128 byte save area if AL = 0, 2 or 3)
  831. Return: AL = 12h if function supported
  832. ---------------------------------------------
  833. INT 10 - VIDEO - ALTERNATE FUNCTION SELECT (PS, VGA) - VIDEO REFRESH CONTROL
  834.     AH = 12h
  835.     BL = 36h
  836.     AL = 00h enable refresh
  837.          01h disable refresh
  838. Return: AL = 12h if function supported
  839. ---------------------------------------------
  840. INT 10 - VIDEO - ALTERNATE FUNCTION SELECT - ???
  841.     AH = 12h
  842.     BX = 5500h ??? (used by ATI and TAXAN)
  843.     BX = 5502h ??? (used by ATI and TAXAN)
  844. ---------------------------------------------
  845. INT 10 - VIDEO - WRITE STRING (AT,XT286,PS,EGA,VGA)
  846.     AH = 13h
  847.     AL = mode
  848.         bit 1: set if string contains alternating characters and attributes
  849.         bit 0: set in order to move cursor after write
  850.     BL = attribute if AL bit 1 clear
  851.     BH = display page number
  852.     DH,DL = row,column of starting cursor position
  853.     CX = length of string
  854.     ES:BP -> start of string
  855. Note: recognizes CR, LF, BS, and bell
  856. ---------------------------------------------
  857. INT 10 - VIDEO - LOAD USER-SPECIFIED LCD CHARACTER FONT (CONVERTIBLE)
  858.     AX = 1400h
  859.     ES:DI -> character font
  860.     BH = number of bytes per character
  861.     BL = 00h load main font (block 0)
  862.          01h load alternate font (block 1)
  863.     CX = number of characters to store
  864.     DX = character offset into RAM font area
  865. ---------------------------------------------
  866. INT 10 - VIDEO - LOAD SYSTEM ROM DEFAULT LCD CHARACTER FONT (CONVERTIBLE)
  867.     AX = 1401h
  868.     BL = 00h load main font (block 0)
  869.          01h load alternate font (block 1)
  870. ---------------------------------------------
  871. INT 10 - VIDEO - SET MAPPING OF LCD HIGH INTENSITY ATTRIBUTES (CONVERTIBLE)
  872.     AX = 1402h
  873.     BL = 00h ignore high intensity attribute
  874.          01h map high intensity to underscore
  875.          02h map high intensity to reverse video
  876.          03h map high intensity to selected alternate font
  877. ---------------------------------------------
  878. INT 10 - VIDEO - GET PHYSICAL DISPLAY PARAMETERS (CONVERTIBLE)
  879.     AH = 15h
  880. Return: AX = alternate display adapter type
  881.         0000h none
  882.         5140h LCD
  883.         5153h CGA
  884.         5151h mono
  885.     ES:DI -> parameter table (see below)
  886.  
  887. Format of display parameter table:
  888. Offset    Size    Description
  889.  00h    WORD    monitor model number
  890.  02h    WORD    vertical pixels per meter
  891.  04h    WORD    horizontal pixels per meter
  892.  06h    WORD    total vertical pixels
  893.  08h    WORD    total horizontal pixels
  894.  0Ah    WORD    horizontal pixel separation in micrometers
  895.  0Ch    WORD    vertical pixel separation in micrometers
  896. ---------------------------------------------
  897. INT 10 - VIDEO - SET SUPERIMPOSE MODE (Sperry PC)
  898.     AH = 15h
  899.     AL = superimpose mode
  900.         00h show graphics screen
  901.         01h show text screen
  902.         02h show text screen superimposed on graphics screen
  903. ---------------------------------------------
  904. INT 10 - VIDEO - DISPLAY COMBINATION (PS,VGA/MCGA)
  905.     AH = 1Ah
  906.     AL = 00h read display combination code
  907.         Return: BL = active display code (see below)
  908.             BH = alternate display code
  909.          01h set display combination code
  910.         BL = active display code (see below)
  911.         BH = alternate display code
  912. Return: AL = 1Ah if function was supported
  913.  
  914. Values of display combination codes:
  915.     00h no display
  916.     01h monochrome adapter w/ monochrome display
  917.     02h CGA w/ color display
  918.     03h reserved
  919.     04h EGA w/ color display
  920.     05h EGA w/ monochrome display
  921.     06h PGA w/ color display
  922.     07h VGA w/ monochrome analog display
  923.     08h VGA w/ color analog display
  924.     09h reserved
  925.     0Ah MCGA w/ digital color display
  926.     0Bh MCGA w/ monochrome analog display
  927.     0Ch MCGA w/ color analog display
  928.     FFh unknown display type
  929. ---------------------------------------------
  930. INT 10 - VIDEO - FUNCTIONALITY/STATE INFORMATION (PS,VGA/MCGA)
  931.     AH = 1Bh
  932.     BX = implementation type
  933.        = 0000h return funtionality/state information
  934.     ES:DI -> 64 byte buffer for state information (see below)
  935. Return: AL = 1Bh if function supported
  936.         ES:DI buffer filled with state information
  937.  
  938. Format of state information:
  939. Offset    Size    Description
  940.  00h    DWORD    address of static funtionality table (see below)
  941.  04h    BYTE    video mode in effect
  942.  05h    WORD    number of columns
  943.  07h    WORD    length of regen buffer in bytes
  944.  09h    WORD    starting address of regen buffer
  945.  0Bh    WORD    cursor position for page 0
  946.  0Dh    WORD    cursor position for page 1
  947.  0Fh    WORD    cursor position for page 2
  948.  11h    WORD    cursor position for page 3
  949.  13h    WORD    cursor position for page 4
  950.  15h    WORD    cursor position for page 5
  951.  17h    WORD    cursor position for page 6
  952.  19h    WORD    cursor position for page 7
  953.  1Bh    WORD    cursor type
  954.  1Dh    BYTE    active display page
  955.  1Eh    WORD    CRTC port address
  956.  20h    BYTE    current setting of register (3?8)
  957.  21h    BYTE    current setting of register (3?9)
  958.  22h    BYTE    number of rows
  959.  23h    WORD    bytes/character
  960.  25h    BYTE    DCC of active display
  961.  26h    BYTE    DCC of alternate display
  962.  27h    WORD    number of colors supported in current mode
  963.  29h    WORD    number of pages supported in current mode
  964.  2Ah    BYTE    number of scan lines active
  965.         (0,1,2,3) = (200,350,400,480)
  966.  2Bh    BYTE    primary character block
  967.  2Ch    BYTE    secondary character block
  968.  2Dh    BYTE    miscellaneous flags
  969.         bit 0 all modes on all displays on
  970.             1 gray summing on
  971.             2 monochrome display attached
  972.             3 default palette loading disabled
  973.             4 cursor emulation enabled
  974.             5 0 = intensity; 1 = blinking
  975.             6 reserved
  976.             7 reserved
  977.  2Eh  3 BYTEs    reserved
  978.  31h    BYTE    video memory available
  979.         00h = 64K, 01h = 128K, 02h = 192K, 03h = 256K
  980.  32h    BYTE    save pointer state flags
  981.         bit 0 512 character set active
  982.             1 dynamic save area present
  983.             2 alpha font override active
  984.             3 graphics font override active
  985.             4 palette override active
  986.             5 DCC override active
  987.             6 reserved
  988.             7 reserved
  989.  33h 13 BYTEs    reserved
  990.  
  991. Format of Static Functionality Table:
  992. Offset    Size    Description
  993.  00h    BYTE    modes supported #1
  994.         bit 0 to bit 7 = 1 modes 0,1,2,3,4,5,6 supported
  995.  01h    BYTE    modes supported #2
  996.         bit 0 to bit 7 = 1 modes 8,9,0Ah,0Bh,0Ch,0Dh,0Eh,0Fh supported
  997.  02h    BYTE    modes supported #3
  998.         bit 0 to bit 3 = 1 modes 10h,11h,12h,13h supported
  999.         bit 4 to bit 7 reserved
  1000.  03h  4 BYTEs    reserved
  1001.  07h    BYTE    scan lines supported
  1002.         bit 0 to bit 2 = 1 if scan lines 200,350,400 supported
  1003.  08h    BYTE    total number of character blocks available in text modes
  1004.  09h    BYTE    maximum number of active character blocks in text modes
  1005.  0Ah    BYTE    miscellaneous function flags #1
  1006.         bit 0 all modes on all displays function supported
  1007.             1 gray summing function supported
  1008.             2 character font loading function supported
  1009.             3 default palette loading enable/disable supported
  1010.             4 cursor emulation function supported
  1011.             5 EGA palette present
  1012.             6 color palette present
  1013.             7 color paging function supported
  1014.  0Bh    BYTE    miscellaneous function flags #2
  1015.         bit 0 light pen supported
  1016.             1 save/restore state function 1Ch supported
  1017.             2 intensity blinking function supported
  1018.             3 Display Combination Code supported
  1019.           4-7 reserved
  1020.  0Ch    WORD    reserved
  1021.  0Eh    BYTE    save pointer function flags
  1022.         bit 0 512 character set supported
  1023.             1 dynamic save area supported
  1024.             2 alpha font override supported
  1025.             3 graphics font override supported
  1026.             4 palette override supported
  1027.             5 DCC extension supported
  1028.             6 reserved
  1029.             7 reserved
  1030.  0Fh    BYTE    reserved
  1031. ---------------------------------------------
  1032. INT 10 - VIDEO - SAVE/RESTORE VIDEO STATE (PS50+,VGA)
  1033.     AH = 1Ch
  1034.     AL = 00h return state buffer size
  1035.         Return: BX = number of 64 byte blocks needed
  1036.          01h save video state
  1037.         ES:BX -> buffer
  1038.          02h restore video state
  1039.         ES:BX -> buffer containing previously saved state
  1040.     CX = requested states
  1041.          bit 0 video hardware
  1042.          1 BIOS data areas
  1043.          2 color registers and DAC state
  1044.           3-15 reserved
  1045. Return: AL = 1Ch if function supported
  1046. ---------------------------------------------
  1047. INT 10 - VIDEO - SET GRAPHICS MODE (Hercules GRAFIX)
  1048.     AH = 40h
  1049. ---------------------------------------------
  1050. INT 10 - VIDEO - SET TEXT MODE (Hercules GRAFIX)
  1051.     AH = 41h
  1052. ---------------------------------------------
  1053. INT 10 - VIDEO - CLEAR CURRENT PAGE (Hercules GRAFIX)
  1054.     AH = 42h
  1055. ---------------------------------------------
  1056. INT 10 - VIDEO - SELECT DRAWING PAGE (Hercules GRAFIX)
  1057.     AH = 43h
  1058.     AL = page number (0,1)
  1059. ---------------------------------------------
  1060. INT 10 - VIDEO - SELECT DRAWING FUNCTION (Hercules GRAFIX)
  1061.     AH = 44h
  1062.     AL = drawing function
  1063.         00h clear pixels
  1064.         01h set pixels
  1065.         02h invert pixels
  1066. ---------------------------------------------
  1067. INT 10 - VIDEO - SELECT PAGE TO DISPLAY (Hercules GRAFIX)
  1068.     AH = 45h
  1069.     AL = page number (0,1)
  1070. ---------------------------------------------
  1071. INT 10 - VIDEO - DRAW ONE PIXEL (Hercules GRAFIX)
  1072.     AH = 46h
  1073.     DI = x (0-720)
  1074.     BP = y (0-347)
  1075. Note:    function 44h determines operation and function 43h which page to use
  1076. ---------------------------------------------
  1077. INT 10 - VIDEO - FIND PIXEL VALUE (Hercules GRAFIX)
  1078.     AH = 47h
  1079.     DI = x (0-720)
  1080.     BP = y (0-347)
  1081. Return: AL = 00h pixel clear
  1082.     AL = 01h pixel set
  1083. Note:    function 43h specifies which page is used
  1084. ---------------------------------------------
  1085. INT 10 - VIDEO - MOVE TO POINT (Hercules GRAFIX)
  1086.     AH = 48h
  1087.     DI = x (0-720)
  1088.     BP = y (0-347)
  1089. ---------------------------------------------
  1090. INT 10 - VIDEO - DRAW TO POINT (Hercules GRAFIX)
  1091.     AH = 49h
  1092.     DI = x (0-720)
  1093.     BP = y (0-347)
  1094. Note:    function 48h or 49h specify first point, 44h operation and 43h page
  1095.     to use
  1096. ---------------------------------------------
  1097. INT 10 - VIDEO - BLOCK FILL (Hercules GRAFIX)
  1098.     AH = 4Ah
  1099. ---------------------------------------------
  1100. INT 10 - VIDEO - DISPLAY CHARACTER (Hercules GRAFIX)
  1101.     AH = 4Bh
  1102.     AL = character to display
  1103.     DI = x (0-720)
  1104.     BP = y (0-347)
  1105. Note: Unlike the other BIOS character functions character position is
  1106.       specified in pixels rather than rows and columns.
  1107. ---------------------------------------------
  1108. INT 10 - VIDEO - DRAW ARC (Hercules GRAFIX)
  1109.     AH = 4Ch
  1110.     ???
  1111. ---------------------------------------------
  1112. INT 10 - VIDEO - DRAW CIRCLE (Hercules GRAFIX)
  1113.     AH = 4Dh
  1114.     ???
  1115. ---------------------------------------------
  1116. INT 10 - VIDEO - FILL AREA (Hercules GRAFIX)
  1117.     AH = 4Eh
  1118. ---------------------------------------------
  1119. INT 10 - SCROLOCK.COM - INSTALLATION CHECK
  1120.     AH = 50h
  1121. Return: BX = 1954h if installed
  1122.         AL = 00 if inactive, nonzero if active
  1123. Note: SCROLOCK is a utility supplied with System Enhancement Associates' ARC
  1124. ---------------------------------------------
  1125. INT 10 - SCROLOCK.COM - ENABLE/DISABLE
  1126.     AH = 51h
  1127.     AL = state
  1128.         00h disable
  1129.         nonzero enable
  1130. Note: SCROLOCK is a utility supplied with System Enhancement Associates' ARC
  1131. ---------------------------------------------
  1132. INT 10 - Direct Graphics Interface Standard (DGIS) - INQUIRE AVAILABLE DEVICES
  1133.     AX = 6A00h
  1134.     BX = 0000h
  1135.     CX = 0000h
  1136.     DX = buffer length (may be 0)
  1137.     ES:DI -> buffer
  1138. Return: BX = number of bytes stored in buffer
  1139.     CX = bytes required for all descriptions (0 if no DGIS)
  1140. Note:    buffer contains descriptions and addresses of DGIS-compatible display(s)
  1141.     and printer(s)
  1142. ---------------------------------------------
  1143. INT 10 - DGIS - REDIRECT CHARACTER OUTPUT
  1144.     AX = 6A01h
  1145.     CX = 0000h
  1146.     ES:DI = address of device to send INT 10 output to
  1147. Return: CX = 0000h  output could not be redirected
  1148.          else INT 10h output now routed to requested display
  1149. ---------------------------------------------
  1150. INT 10 - DGIS - INQUIRE INT 10 OUTPUT DEVICE
  1151.     AX = 6A02h
  1152.     ES:DI = 0000h:0000h
  1153. Return: ES:DI = 0000h:0000h  if current display is non-DGIS
  1154.         else address of the current DGIS INT 10 display
  1155. ---------------------------------------------
  1156. INT 10 - VIDEO - INSTALLATION CHECK (Video7 VGA,VEGA VGA)
  1157.         AX = 6F00h
  1158. Return: BX = 5637h ('V7') indicates Video7 VGA/VEGA VGA extensions are present
  1159. ---------------------------------------------
  1160. INT 10 - VIDEO - GETINFO (Video7 VGA,VEGA VGA)
  1161.         AX = 6F01h
  1162. Return: AL = monitor type code (VEGA VGA only)
  1163.         AH = status register information
  1164.              bit  0 = display enable
  1165.             0 = display enabled
  1166.             1 = vertical or horizontal retrace in progress
  1167.              bit  1 = light pen flip flop set
  1168.              bit  2 = light pen switch activated
  1169.              bit  3 = vertical sync
  1170.              bit  4 = monitor resolution
  1171.             0 = high resolution (>200 lines)
  1172.             1 = low resolution (<=200 lines)
  1173.              bit  5 = display type
  1174.             0 = color
  1175.             1 = monochrome
  1176.          bits6,7= diagnostic bits
  1177. Note: bits 0-3 are the same as the EGA/VGA status register bits 0-3
  1178. ---------------------------------------------
  1179. INT 10 - VIDEO - GET MODE AND SCREEN RESOLUTION (Video7 VGA, VEGA VGA)
  1180.         AX = 6F04h
  1181. Return: AL = current video mode (see AX=6F05h)
  1182.         BX = horizontal columns (text) or pixels (graphics)
  1183.         CX = vertical columns (text) or pixels (graphics)
  1184. ---------------------------------------------
  1185. INT 10 - VIDEO - SET VIDEO MODE (Video7 VGA, VEGA EXTENDED EGA/VGA)
  1186.     AX = 6F05h
  1187.     BL = mode (graphics mode if graphics resolution listed)
  1188.          text  pixel graphic color disp scrn  system
  1189.          resol    box  resoltn       page addr
  1190.        00h-13h = standard IBM modes
  1191.        40h = 80x43  8x8                 Video7/VEGA VGA
  1192.        41h = 132x25 8x14                 Video7/VEGA VGA
  1193.        42h = 132x43 8x8                 Video7/VEGA VGA
  1194.        43h = 80x60  8x8                 Video7/VEGA VGA
  1195.        44h = 100x60 8x8                 Video7/VEGA VGA
  1196.        45h = 132x28 8x8                 Video7/VEGA VGA
  1197.        60h =         752x410  16         Video7 VGA, VEGA VGA
  1198.        61h =         720x540  16         Video7 VGA, VEGA VGA
  1199.        62h =         800x600  16         Video7 VGA, VEGA Ext EGA
  1200.        63h =        1024x768   2         Video7 VGA
  1201.        64h =        1024x768   4         Video7 VGA
  1202.        65h =        1024x768  16         Video7 VGA, VEGA Ext EGA
  1203.        66h =         640x400 256         Video7 VGA, VEGA Ext VGA
  1204.        67h =         640x480 256         Video7 VGA, VEGA Ext VGA
  1205.        68h =         720x540 256         Video7 VGA, VEGA Ext VGA
  1206.        69h =         800x600 256         Video7 VGA, VEGA Ext VGA
  1207.        70h =         752x410  16gray         Video7 VGA, VEGA VGA
  1208.        71h =         720x540  16gray         Video7 VGA, VEGA VGA
  1209.        72h =         800x600  16gray         Video7 VGA
  1210.        73h =        1024x768   2gray         Video7 VGA
  1211.        74h =        1024x768   4gray         Video7 VGA
  1212.        75h =        1024x768  16gray         Video7 VGA
  1213.        76h =         640x400 256gray         Video7 VGA
  1214.        77h =         640x480 256gray         Video7 VGA
  1215.        78h =         720x540 256gray         Video7 VGA
  1216.        79h =         800x600 256gray         (future)
  1217. ---------------------------------------------
  1218. INT 10 - VIDEO - SELECT AUTOSWITCH MODE (V7VGA,VEGA VGA)
  1219.         AX = 6F06h
  1220.         BL = Autoswitch mode select
  1221.              00h select EGA/VGA-only modes
  1222.              01h select Autoswitched VGA/EGA/CGA/MGA modes
  1223.              02h select 'bootup' CGA/MGA modes
  1224.         BH = enable/disable (00h enable, 01h = disable selection)
  1225. ---------------------------------------------
  1226. INT 10 - VIDEO - GET VIDEO MEMORY CONFIGURATION (V7VGA,VEGA VGA)
  1227.         AX = 6F07h
  1228. Return: AL = 6Fh
  1229.         AH = bits 0-6 = number of 256K blocks of video memory
  1230.              bit 7    = DRAM/VRAM (0: DRAM, 1: VRAM)
  1231.         BH = chip revision (SR8F) (S/C Chip in VEGA VGA)
  1232.         BL = chip revision (SR8E) (G/A Chip in VEGA VGA)
  1233.         CX = 0000h
  1234. ---------------------------------------------
  1235. INT 10 - VIDEO - GET VIDEO RAM ADDRESS (TANDY 1000)
  1236.     AH = 70h
  1237. Return: AX  = segment address of the following
  1238.     [BX] = offset address of green plane
  1239.     [CX] = segment address of green plane
  1240.     [DX] = segment address of red/blue plane
  1241.            (red offset = 0, blue offset = 4000)
  1242. ---------------------------------------------
  1243. INT 10 - VIDEO - GET INCRAM ADDRESSES (TANDY 1000)
  1244.     AH = 71h
  1245. Return: AX  = segment address of the following
  1246.     [BX] = segment address of INCRAM
  1247.     [CX] = offset address of INCRAM
  1248. ---------------------------------------------
  1249. INT 10 - VIDEO - SCROLL SCREEN RIGHT (TANDY 1000)
  1250.     AH = 72h
  1251.     AL = number of columns blanked at left of window
  1252.          00h = blank entire window
  1253.     BH = attributes to be used on blank columns
  1254.     CH,CL = row, column of upper left corner of window
  1255.     DH,DL = row, column of lower right corner
  1256. --------------------------------------------
  1257. INT 10 - VIDEO - SCROLL SCREEN LEFT (TANDY 1000)
  1258.     AH = 73h
  1259.     AL = number of columns blanked at right of window
  1260.          00h = blank entire window
  1261.     BH = attributes to be used on blank columns
  1262.     CH,CL = row, column of upper left corner of window
  1263.     DH,DL = row, column of lower right corner
  1264. ---------------------------------------------
  1265. INT 10 - VIDEO (DESQview 2.0x only) - internal - SET ??? HANDLER
  1266.     AH = 80h
  1267.     DX = 4456h ('DV')
  1268.     ES:DI -> FAR subroutine to be called on ???
  1269. Return: DS = segment of DESQview data structure for video buffer
  1270. Note: this function is probably meant for internal use only, due to the magic
  1271.       value required in DX
  1272.       the subroutine seems to be called when the DESQview menu is accessed;
  1273.     on entry, AL = 3 or 4
  1274. ---------------------------------------------
  1275. INT 10 - VIDEO (DESQview 2.0x only) - internal - GET ???
  1276.     AH = 81h
  1277.     DX = 4456h ('DV')
  1278. Return: ES = segment of DESQview data structure for video buffer
  1279.         BYTE ES:[0] = current window number in DV 2.0x
  1280. Note: this function is probably meant for internal use only, due to the magic
  1281.       value required in DX
  1282. ---------------------------------------------
  1283. INT 10 - VIDEO (DESQview 2.0x only) - internal - GET CURRENT WINDOW INFO
  1284.     AH = 82h
  1285.     DX = 4456h ('DV')
  1286. Return: DS = segment in DESQview for data structure
  1287.          in DV 2.00,
  1288.           BYTE DS:[0] = window number
  1289.           WORD DS:[1] = segment of other data structure
  1290.           WORD DS:[3] = segment of window's object handle
  1291.     ES = segment of DESQview data structure for video buffer
  1292.     AL = current window number
  1293.     AH = ???
  1294.     BL = direct screen writes
  1295.         00h program does not do direct writes
  1296.         01h program does direct writes, so shadow buffer not usable
  1297.     BH = ???
  1298.     CL = current video mode
  1299.     CH = ???
  1300. Note: this function is probably meant for internal use only, due to the magic
  1301.       value required in DX
  1302. ---------------------------------------------
  1303. INT 10 - VIDEO - Compaq Portable Extensions - SELECT EXTERNAL MONITOR
  1304.     AX = BF00h
  1305. Note:    all registers preserved and the internal monitor is blanked
  1306.     the external monitor becomes the active monitor
  1307. ---------------------------------------------
  1308. INT 10 - VIDEO - Compaq Portable Extensions - SELECT INTERNAL MONITOR
  1309.     AX = BF01h
  1310. Note:    all registers preserved and the external monitor is blanked
  1311.     the internal monitor becomes the active monitor
  1312. ---------------------------------------------
  1313. INT 10 - VIDEO - Compaq Portable Extensions - SET MASTER MODE OF CURRENT CTRLR
  1314.     AX = BF02h
  1315.     BH = master mode
  1316.         04h CGA
  1317.         05h EGA
  1318.         07h MDA
  1319. ---------------------------------------------
  1320. INT 10 - VIDEO - Compaq Portable Extensions - GET ENVIRONMENT
  1321.     AX = BF03h
  1322.     BX = 0000h
  1323. Return: BH = active monitor
  1324.         00h = external
  1325.         01h = internal
  1326.     BL = master mode
  1327.         00h = switchable VDU not present
  1328.         04h = CGA
  1329.         05h = EGA
  1330.         07h = MDA
  1331.     CH = 00h (reserved)
  1332.     CL = switchable VDU mode supported
  1333.         bit  0   = CGA supported
  1334.         bits 1,2 = reserved (1)
  1335.         bit  3   = MDA supported
  1336.         bits 4-7 = reserved (1)
  1337.     DH = internal monitor type
  1338.         00h = none
  1339.         01h = Dual-mode monitor
  1340.         02h = 5153 RGB monitor
  1341.         03h = Compaq Color monitor
  1342.         04h = 640x400 flat panel
  1343.     DL = external monitor type
  1344.         00h = none
  1345.         01h = dual-mode monitor
  1346.         02h = 5153 RGB monitor
  1347.         03h = Compaq Color monitor
  1348.         04h = 640x400 flat panel
  1349. ---------------------------------------------
  1350. INT 10 - VIDEO - Compaq Portable Extensions - SET MODE SWITCH DELAY
  1351.     AX = BF04h
  1352.     BH = 00h enable delay
  1353.          01h disable delay
  1354. ---------------------------------------------
  1355. INT 10 - VIDEO - MSHERC.COM - INSTALLATION CHECK???
  1356.     AH = EFh
  1357. Return: DX = ???
  1358. Note:    MSHERC.COM is a program included with the PC Tech Journal high-level
  1359.     benchmark suite that adds video modes 08h and 88h for Hercules cards,
  1360.     and supports text in the new graphics modes.
  1361. ---------------------------------------------
  1362. INT 10 - Microsoft Mouse driver EGA support - READ ONE REGISTER
  1363.     AH = F0h
  1364.     BL = register number
  1365.     DX = group index
  1366.         Pointer/data chips
  1367.            00h CRT Controller (25 reg) 3B4h mono modes, 3D4h color modes
  1368.            08h Sequencer (5 registers) 3C4h
  1369.            10h Graphics Controller (9 registers) 3CEh
  1370.            18h Attribute Controller (20 registers) 3C0h
  1371.         Single registers
  1372.            20h Miscellaneous Output register 3C2h
  1373.            28h Feature Control register (3BAh mono modes, 3DAh color modes)
  1374.            30h Graphics 1 Position register 3CCh
  1375.            38h Graphics 2 Position register 3CAh
  1376. Return: BL = data
  1377. ---------------------------------------------
  1378. INT 10 - Microsoft Mouse driver EGA support - WRITE ONE REGISTER
  1379.     AH = F1h
  1380.     DX = group index (see AH=F0h)
  1381.     BL = register number
  1382.     BH = value to write
  1383. Return: BL = data
  1384. ---------------------------------------------
  1385. INT 10 - Microsoft Mouse driver EGA support - READ REGISTER RANGE
  1386.     AH = F2h
  1387.     CH = starting register number
  1388.     CL = Number of registers (>1)
  1389.     DX = group index
  1390.          00h CRTC (3B4h mono modes, 3D4h color modes)
  1391.          08h Sequencer 3C4h
  1392.          10h Graphics Controller 3CEh
  1393.          18h Attribute Controller 3C0h
  1394.     ES:BX -> buffer, CL bytes
  1395. ---------------------------------------------
  1396. INT 10 - Microsoft Mouse driver EGA support - WRITE REGISTER RANGE
  1397.     AH = F3h
  1398.     CH = starting register
  1399.     CL = number of registers (>1)
  1400.     DX = group index (see AH=F2h)
  1401.     ES:BX -> buffer, CL bytes
  1402. ---------------------------------------------
  1403. INT 10 - Microsoft Mouse driver EGA support - READ REGISTER SET
  1404.     AH = F4h
  1405.     CX = number of registers to read (>1)
  1406.     ES:BX -> table of records (see below)
  1407. Return: register values in table filled in
  1408.  
  1409. Format of entries in table of register records:
  1410. Offset    Size    Description
  1411.  00h    WORD    group index
  1412.         Pointer/data chips
  1413.            00h CRTC (3B4h mono modes, 3D4h color modes)
  1414.            08h Sequencer 3C4h
  1415.            10h Graphics Controller 3CEh
  1416.            18h Attribute Controller 3C0h
  1417.         Single registers
  1418.            20h Miscellaneous Output register 3C2h
  1419.            28h Feature Control register (3BAh mono modes, 3DAh color)
  1420.            30h Graphics 1 Position register 3CCh
  1421.            38h Graphics 2 Position register 3CAh
  1422.  02h    BYTE    register number (0 for single registers)
  1423.  03h    BYTE    register value
  1424. ---------------------------------------------
  1425. INT 10 - Microsoft Mouse driver EGA support - WRITE REGISTER SET
  1426.     AH = F5h
  1427.     CX = number of registers to write (>1)
  1428.     ES:BX -> table of records (see AH=F4h)
  1429. --------------------------------------------
  1430. INT 10 - Microsoft Mouse driver EGA support - REVERT TO DEFAULT REGISTERS
  1431.     AH = F6h
  1432. --------------------------------------------
  1433. INT 10 - Microsoft Mouse driver EGA support - DEFINE DEFAULT REGISTER TABLE
  1434.     AH = F7h
  1435.     DX = port number
  1436.        Pointer/data chips
  1437.           00h CRTC (3B4h mono modes, 3D4h color modes)
  1438.           08h Sequencer 3C4h
  1439.           10h Graphics Controller 3CEh
  1440.           18h Attribute Controller 3C0h
  1441.        Single registers
  1442.           20h Miscellaneous Output register 3C2h
  1443.           28h Feature Control register (3BAh mono modes, 3DAh color modes)
  1444.           30h Graphics 1 Position register 3CCh
  1445.           38h Graphics 2 Position register 3CAh
  1446.     ES:BX -> table of one-byte entries, one byte to be written to each
  1447.          register
  1448. --------------------------------------------
  1449. INT 10 - Microsoft Mouse driver EGA support - INTERROGATE DRIVER
  1450.     AH = FAh
  1451.     BX = 0000h
  1452. Return: BX = 0000h if mouse driver not present
  1453.     ES:BX -> EGA Register Interface version number, if present:
  1454.         byte 0 = major release number
  1455.         byte 1 = minor release number
  1456. --------------------------------------------
  1457. INT 10 - FASTBUFF.COM - INSTALLATION CHECK
  1458.     AH = FAh
  1459. Return: AX = 00FAh if installed
  1460.         ES = segment of resident code
  1461. Note:    FASTBUFF.COM is a keyboard speedup/screen blanking utility by 
  1462.     David Steiner
  1463. --------------------------------------------
  1464. INT 10 - VIDEO (TopView) - GET VIDEO BUFFER
  1465.     AH = FEh
  1466.     ES:DI = segment:offset of assumed video buffer
  1467. Return: ES:DI = segment:offset of actual video buffer
  1468. ---------------------------------------------
  1469. INT 10 - VIDEO (TopView) - UPDATE REAL SCREEN FROM VIDEO BUFFER
  1470.     AH = FFh
  1471.     CX = number of sequential characters that have been modified
  1472.     DI = offset of first character that has been modified
  1473.     ES = segment of video buffer
  1474. Note: avoid CX=0
  1475. ---------------------------------------------
  1476. INT 11 - EQUIPMENT DETERMINATION
  1477. Return: AX = equipment flag bits
  1478.         0      diskette installed
  1479.         1      8087 present
  1480.         2      mouse installed (PS2 only)
  1481.         2,3   number of 16K banks of RAM on motherboard (PC only)
  1482.           number of 64K banks of RAM on motherboard (XT only)
  1483.           always = 11 on AT and above
  1484.         4,5   initial video mode
  1485.           01 = 40x25 color
  1486.           10 = 80x25 color
  1487.           11 = 80X25 IBM monochrome
  1488.         6,7   number of diskette drives (only if bit 0 = 1)
  1489.           00 = 1, 01 = 2, 10 = 3, 11 = 4
  1490.         8      0 = DMA present, 1 = no DMA on system (PCjr)
  1491.         9-11  number of RS232 cards
  1492.         12      game I/O attached
  1493.         13      serial printer installed (PCjr)
  1494.           internal modem installed (PC/Convertible)
  1495.         14,15 number of printers
  1496. ---------------------------------------------
  1497. INT 12 - MEMORY SIZE
  1498. Return: AX = number of contiguous 1K blocks of memory
  1499. ---------------------------------------------
  1500. INT 13 - DISK - RESET DISK SYSTEM
  1501.     AH = 00h
  1502.     DL = drive (if bit 7 is set both hard disks and floppy disks reset)
  1503. ---------------------------------------------
  1504. INT 13 - DISK - STATUS OF DISK SYSTEM
  1505.     AH = 01h
  1506. Return: AL = status of last disk operation
  1507.         00h = successful completion
  1508.         01h = bad command
  1509.         02h = address mark not found
  1510.         03h = write attempted on write-protected disk
  1511.         04h = sector not found
  1512.         05h = reset failed (hard disk)
  1513.         06h = diskette changed
  1514.         07h = parameter act. failed (hard disk)
  1515.         08h = DMA overrun (floppy disk)
  1516.         09h = DMA across 64K boundary
  1517.         0Ah = bad sector detected (hard disk)
  1518.         0Bh = bad track detected (hard disk)
  1519.         0Ch = unsupported track
  1520.         0Dh = invalid number of sectors on format (hard disk)
  1521.         0Eh = control data address mark detected (hard disk)
  1522.         0Fh = DMA arbitration error (hard disk)
  1523.         10h = bad CRC/ECC
  1524.         11h = data ECC corrected (hard disk)
  1525.         20h = controller failure
  1526.         40h = seek failed
  1527.         80h = time out
  1528.         AAh = drive not ready (hard disk)
  1529.         BBh = undefined error (hard disk)
  1530.         CCh = write fault (hard disk)
  1531.         E0h = status register error (hard disk)
  1532.         FFh = sense operation failed (hard disk)
  1533. ---------------------------------------------
  1534. INT 13 - DISK - READ SECTORS INTO MEMORY
  1535.     AH = 02h
  1536.     AL = number of sectors to read
  1537.     CH = track (for hard disk, bits 8,9 in high bits of CL)
  1538.     CL = sector
  1539.     DH = head
  1540.     DL = drive
  1541.     ES:BX -> buffer to fill
  1542. Return: CF set on error
  1543.     AH = status (see AH=01h)
  1544.     AL = number of sectors read
  1545. ---------------------------------------------
  1546. INT 13 - DISK - WRITE SECTORS FROM MEMORY
  1547.     AH = 03h
  1548.     AL = number of sectors to write
  1549.     CH = track (if hard disk, bits 8,9 in high bits of CL)
  1550.     CL = sector (if hard disk, high two bits are high bits of track #)
  1551.     DH = head
  1552.     DL = drive
  1553.     ES:BX -> buffer
  1554. Return: CF set on error
  1555.     AH = status (see AH=01h)
  1556.     AL = number of sectors written
  1557. ---------------------------------------------
  1558. INT 13 - DISK - VERIFY SECTORS
  1559.     AH = 04h
  1560.     AL = number of sectors to verify
  1561.     CH = track (for hard disk, bits 8,9 in high bits of CL)
  1562.     CL = sector
  1563.     DH = head
  1564.     DL = drive
  1565. Return: CF set on error
  1566.     AH = status (see AH=01h)
  1567.     AL = number of sectors verified
  1568. ---------------------------------------------
  1569. INT 13 - FLOPPY - FORMAT TRACK
  1570.     AH = 05h
  1571.     AL = number of sectors to create on this track
  1572.     CH = track
  1573.     CL = sector
  1574.     DH = head
  1575.     DL = drive
  1576.     ES:BX -> array of 4-byte address fields
  1577.            byte 1 = track
  1578.            byte 2 = head
  1579.            byte 3 = sector
  1580.            byte 4 = bytes/sector  0=128, 1=256, 2=512, 3=1024
  1581. Return: CF set if error occurred
  1582.     AH = status code (see AH=01h)
  1583. ---------------------------------------------
  1584. INT 13 - FIXED DISK - FORMAT TRACK
  1585.     AH = 05h
  1586.     AL = interleave value (XT only)
  1587.     ES:BX = 512-byte format buffer
  1588.         the first 2*(sectors/track) bytes contain F,N for each sector
  1589.            F = 00 for good sector, 80h for bad sector
  1590.            N = sector number
  1591.     CH = cylinder number (bits 8,9 in high bits of CL)
  1592.     CL = sector number
  1593.     DH = head
  1594.     DL = drive
  1595. Return: AH = status code (see AH=01h)
  1596. ---------------------------------------------
  1597. INT 13 - FIXED DISK - FORMAT TRACK AND SET BAD SECTOR FLAGS (XT,PORT)
  1598.     AH = 06h
  1599.     AL = interleave value
  1600.     CH = cylinder number (bits 8,9 in high bits of CL)
  1601.     CL = sector number
  1602.     DH = head
  1603.     DL = drive
  1604. Return: AH = status code (see AH=01h)
  1605. ---------------------------------------------
  1606. INT 13 - FIXED DISK - FORMAT DRIVE STARTING AT GIVEN TRACK (XT,PORT)
  1607.     AH = 07h
  1608.     AL = interleave value (XT only)
  1609.     ES:BX = 512-byte format buffer (see AH=05h)
  1610.     CH = cylinder number (bits 8,9 in high bits of CL)
  1611.     CL = sector number
  1612.     DH = head
  1613.     DL = drive
  1614. Return: AH = status code (see AH=01h)
  1615. ---------------------------------------------
  1616. INT 13 - DISK - GET CURRENT DRIVE PARAMETERS (XT,AT,XT286,CONV,PS)
  1617.     AH = 08h
  1618.     DL = drive number
  1619. Return: CF set on error
  1620.     AH = status code (see AH=01h)
  1621.     BL = drive type (see AH=17h) (AT/PS2 floppies only)
  1622.     DL = number of consecutive acknowledging drives
  1623.     DH = maximum value for head number
  1624.     CL = maximum value fo sector number
  1625.     CH = maximum value for cylinder number
  1626.     ES:DI = drive parameter table
  1627. ---------------------------------------------
  1628. INT 13 - FIXED DISK - INITIALIZE TWO FIXED DISK BASE TABLES (XT,AT,XT286,PS)
  1629.     AH = 09h
  1630. Return: CF set on error
  1631.     AH = status code (see AH=01h)
  1632.     INT 41h points to table for drive 0
  1633.     INT 46h points to table for drive 1
  1634. ---------------------------------------------
  1635. INT 13 - FIXED DISK - READ LONG (XT,AT,XT286,PS)
  1636.     AH = 0Ah
  1637.     DL = drive ID
  1638.     DH = head
  1639.     CH = cylinder (bits 8,9 in high bits of CL)
  1640.     CL = sector
  1641.     ES:BX -> buffer to fill
  1642. Return: CF set on error
  1643.     AH = status code (see AH=01h)
  1644.     AL = number of sectors read
  1645. Note: used for diagnostics only on PS/2 systems
  1646. ---------------------------------------------
  1647. INT 13 - FIXED DISK - WRITE LONG (XT,AT,XT286,PS)
  1648.     AH = 0Bh
  1649.     DL = drive ID
  1650.     DH = head
  1651.     CH = cylinder (bits 8,9 in high bits of CL)
  1652.     CL = sector
  1653.     ES:BX -> buffer containing data
  1654. Return: CF set on error
  1655.     AH = status code (see AH=01h)
  1656.     AL = number of sectors written
  1657. Note: used for diagnostics only on PS/2 systems
  1658. ---------------------------------------------
  1659. INT 13 - FIXED DISK - SEEK TO CYLINDER (XT,AT,XT286,PS)
  1660.     AH = 0Ch
  1661.     DL = drive ID
  1662.     DH = head
  1663.     CH = cylinder (bits 8,9 in high bits of CL)
  1664. Return: CF set on error
  1665.     AH = status code (see AH=01h)
  1666. ---------------------------------------------
  1667. INT 13 - FIXED DISK - ALTERNATE DISK RESET (XT,AT,XT286,PS)
  1668.     AH = 0Dh
  1669.     DL = drive ID
  1670. Return: CF set on error
  1671.     AH = status code (see AH=01h)
  1672. ---------------------------------------------
  1673. INT 13 - FIXED DISK - READ SECTOR BUFFER (XT,PS)
  1674.     AH = 0Eh
  1675.     ES:BX -> buffer
  1676. Return: CF set on error
  1677.     AH = status code (see AH=01h)
  1678. Notes: transfers controller's sector buffer.  No data is read from the drive
  1679.        used for diagnostics only on PS/2 systems
  1680. ---------------------------------------------
  1681. INT 13 - FIXED DISK - WRITE SECTOR BUFFER (XT,PS)
  1682.     AH = 0Fh
  1683.     ES:BX -> buffer
  1684. Return: CF set on error
  1685.     AH = status code (see AH=01h)
  1686. Notes:    should be called before formatting to initialize the controller's
  1687.     sector buffer.
  1688.     used for diagnostics only on PS/2 systems
  1689. ---------------------------------------------
  1690. INT 13 - FIXED DISK - TEST FOR DRIVE READY (XT,AT,XT286,PS)
  1691.     AH = 10h
  1692.     DL = drive ID
  1693. Return: CF set on error
  1694.     AH = status code (see AH=01h)
  1695. ---------------------------------------------
  1696. INT 13 - FIXED DISK - RECALIBRATE DRIVE (XT,AT,XT286,PS)
  1697.     AH = 11h
  1698.     DL = drive ID
  1699. Return: CF set on error
  1700.     AH = status code (see AH=01h)
  1701. ---------------------------------------------
  1702. INT 13 - FIXED DISK - CONTROLER RAM DIAGNOSTIC (XT,PS)
  1703.     AH = 12h
  1704. Return: CF set on error
  1705.     AH = status code (see AH=01h)
  1706. Note: used for diagnostics only on PS/2 systems
  1707. ---------------------------------------------
  1708. INT 13 - FIXED DISK - DRIVE DIAGNOSTIC (XT,PS)
  1709.     AH = 13h
  1710. Return: CF set on error
  1711.     AH = status code (see AH=01h)
  1712. Note: used for diagnostics only on PS/2 systems
  1713. ---------------------------------------------
  1714. INT 13 - FIXED DISK - CONTROLLER DIAGNOSTICS (XT,AT,XT286,PS)
  1715.     AH = 14h
  1716. Return: CF set on error
  1717.     AH = status code (see AH=01h)
  1718. Note: used for diagnostics only on PS/2 systems
  1719. ---------------------------------------------
  1720. INT 13 - DISK - GET TYPE (AT,XT2,XT286,CONV,PS)
  1721.     AH = 15h
  1722.     DL = drive ID
  1723. Return: CF set on error
  1724.     AH = disk type
  1725.         00h = disk not there
  1726.         01h = floppy, no change detection present
  1727.         02h = floppy with change detection
  1728.         03h = fixed disk
  1729.            CX:DX = number of 512-byte sectors
  1730. ---------------------------------------------
  1731. INT 13 - FLOPPY DISK - CHANGE OF DISK STATUS (AT,XT2,XT286,CONV,PS)
  1732.     AH = 16h
  1733.     DL = drive to check
  1734. Return: AH = disk change status
  1735.         00h = no disk change
  1736.         06h = disk changed
  1737. ---------------------------------------------
  1738. INT 13 - DISK - SET TYPE (AT,XT2,XT286,CONV,PS)
  1739.     AH = 17h
  1740.     AL = disk type
  1741.         00h = no disk
  1742.         01h = regular disk in regular drive
  1743.         02h = regular disk in high-capacity drive
  1744.         03h = high-capacity disk in high-capacity drive
  1745.         04h = 720K disk in 720K drive
  1746.     DL = drive ID
  1747. ---------------------------------------------
  1748. INT 13 - DISK - SET MEDIA TYPE FOR FORMAT (AT model 3x9,XT2,XT286,PS)
  1749.     AH = 18h
  1750.     DL = drive number
  1751.     CH = lower 8 bits of number of tracks
  1752.     CL = sectors per track (bits 0-5)
  1753.          top 2 bits of number of tracks (bits 6,7)
  1754. Return: AH = 00h  requested combination supported
  1755.          01h  function not available
  1756.          0Ch  not supported or drive type unknown
  1757.          80h  there is no disk in the drive
  1758.     ES:DI -> 11-byte parameter table
  1759. ---------------------------------------------
  1760. INT 13 - FIXED DISK - PARK HEADS (XT286,PS)
  1761.     AH = 19h
  1762.     DL = drive
  1763. Return: CF set on error
  1764.     AH = status (see AH=01h)
  1765. ---------------------------------------------
  1766. INT 13 - ESDI FIXED DISK - FORMAT UNIT (PS)
  1767.     AH = 1Ah
  1768.     AL = defect table count
  1769.     CL = format modifiers
  1770.         bit 4: generate periodic interrupt
  1771.         bit 3: perform surface analysis
  1772.         bit 2: update secondary defect map
  1773.         bit 1: ignore secondary defect map
  1774.         bit 0: ignore primary defect map
  1775.     DL = drive
  1776.     ES:BX -> defect table
  1777. Return: CF set on error
  1778.     AH = status (see AH=01h)
  1779. Note:    if periodic interrupt selected, INT 15h/AH=0Fh is called after each
  1780.     cylinder is formatted
  1781. ---------------------------------------------
  1782. INT 13 - ESDI FIXED DISK - GET MANUFACTURING HEADER
  1783.     AH = 1Bh
  1784.     AL = number of record
  1785.     DL = drive
  1786.     ES:BX -> buffer for manufacturing header (defect list)
  1787. Return: CF set on error
  1788.         AH = status
  1789. Note:    manufacturing header format (Defect Map Record format) can be found
  1790.     in IBM 70MB, 115MB Fixed Disk Drives Technical Reference
  1791. ---------------------------------------------
  1792. INT 13 - ESDI FIXED DISK - GET DEVICE CONFIGURATION
  1793.     AX = 1C0Ah
  1794.     DL = drive
  1795.     ES:BX -> buffer for device configuration (drive physical parameter)
  1796. Return: CF set on error
  1797.         AH = status
  1798. Note:    device configuration format can be found in IBM ESDI Fixed Disk Drive
  1799.     Adapter/A Technical Reference
  1800. ---------------------------------------------
  1801. INT 13 - ESDI FIXED DISK - GET ADAPTER CONFIGURATION
  1802.     AX = 1C0Bh
  1803.     ES:BX -> buffer for adapter configuration
  1804. Return: CF set on error
  1805.         AH = status
  1806. ---------------------------------------------
  1807. INT 13 - ESDI FIXED DISK - GET POS INFORMATION
  1808.     AX = 1C0Ch
  1809.     ES:BX -> POS information
  1810. Return: CF set on error
  1811.         AH = status
  1812. ---------------------------------------------
  1813. INT 13 - ESDI FIXED DISK - TRANSLATE RBA TO ABA
  1814.     AX = 1C0Eh
  1815.     CH = low 8 bits of cylinder number
  1816.     CL = sector number, high two bits of cylinder number in bits 6 and 7
  1817.     DH = head number
  1818.     DL = drive number
  1819.     ES:BX -> ABA number
  1820. Return: CF set on error
  1821.         AH = status
  1822. Note:    ABA (absolute block address) format can be found in IBM ESDI Adapter
  1823.     Technical Reference by using it's Device Configuration Status Block
  1824. ---------------------------------------------
  1825. INT 13 - DISK - ??? (Western Digital "Super BIOS")
  1826.     AH = 20h
  1827.     ???
  1828. Return: ???
  1829. Note: seems to return some kind of status
  1830. ---------------------------------------------
  1831. INT 14 - SERIAL I/O - INITIALIZE USART
  1832.     AH = 00h
  1833.     AL = initializing parameters
  1834.         7 - 6 - 5       4 - 3     2      1 - 0
  1835.         -BAUD RATE-    PARITY   STOP   WORD
  1836.                     BITS  LENGTH
  1837.         000  110 bd    00 none  0: 1   00: 5
  1838.         001  150 bd    01 odd   1: 2   01: 6
  1839.         010  300 bd    11 even       10: 7
  1840.         011  600 bd            11: 8
  1841.         100 1200 bd
  1842.         101 2400 bd
  1843.         110 4800 bd
  1844.         111 9600 bd (4800 on PCjr)
  1845.     DX = port number (0-3)
  1846. Return: AH = RS-232 status code bits
  1847.         0: data ready
  1848.         1: overrun error
  1849.         2: parity error
  1850.         3: framing error
  1851.         4: break detected
  1852.         5: transmission buffer register empty
  1853.         6: transmission shift register empty
  1854.         7: time out--if set, other bits invalid
  1855.     AL = modem status bits
  1856.         0: delta Clear-To-Send
  1857.         1: delta Data-Set-Ready
  1858.         2: trailing edge of ring detected
  1859.         3: change in receive line signal detected
  1860.         4: Clear-To-Send
  1861.         5: Data-Set-Ready
  1862.         6: ring detected
  1863.         7: receive line signal detected
  1864. ---------------------------------------------
  1865. INT 14 - FOSSIL (Fido/Opus/Seadog Standard Interface Level) - INITIALIZE
  1866.     AH = 00h
  1867.     AL = initializing parameters
  1868.         7 - 6 - 5       4 - 3     2      1 - 0
  1869.         -BAUD RATE-    PARITY   STOP   WORD
  1870.                     BITS  LENGTH
  1871.         000 19200 bd   00 none  0: 1  00: 5
  1872.         001 38400 bd   01 odd   1: 2  01: 6
  1873.         010   300 bd   11 even      10: 7
  1874.         011   600 bd          11: 8
  1875.         100  1200 bd
  1876.         101  2400 bd
  1877.         110  4800 bd
  1878.         111  9600 bd (4800 on PCjr)
  1879.     DX = port number (0-3 or FFh if only performing non-I/O setup)
  1880. Return: AH = RS-232 status code bits
  1881.         0: RDA - input data is available in buffer
  1882.         1: OVRN - data has been lost
  1883.         5: THRE - room is available in output buffer
  1884.         6: TSRE - output buffer empty
  1885.     AL = modem status bits
  1886.         3: always 1
  1887.         7: DCD - carrier detect
  1888. ---------------------------------------------
  1889. INT 14 - SERIAL I/O - TRANSMIT CHARACTER
  1890.     AH = 01h
  1891.     AL = character
  1892.     DX = port number (0-3)
  1893. Return: AX = port status (see AH=00h)
  1894. ---------------------------------------------
  1895. INT 14 - SERIAL I/O - RECEIVE CHARACTER
  1896.     AH = 02h
  1897.     DX = port number (0-3)
  1898. Return: AL = character received
  1899.     AH = RS-232 status code (see AH=00h)
  1900. Note:    will timeout if DSR is not asserted, even if function 03h returns
  1901.     data ready
  1902. ---------------------------------------------
  1903. INT 14 - FOSSIL - RECEIVE CHARACTER WITH WAIT
  1904.     AH = 02h
  1905.     DX = port number (0-3)
  1906. Return: AL = character received
  1907.     AH = 00h
  1908. ---------------------------------------------
  1909. INT 14 - SERIAL I/O - GET USART STATUS
  1910.     AH = 03h
  1911.     DX = port number (0-3)
  1912. Return: AX = port status code (see AH=00h)
  1913. ---------------------------------------------
  1914. INT 14 - SERIAL I/O - EXTENDED INITIALIZE (CONVERTIBLE,PS)
  1915.     AH = 04h
  1916.     AL = break status
  1917.         00h if break
  1918.         01h if no break
  1919.     BH = parity
  1920.         00h no parity
  1921.         01h odd parity
  1922.         02h even parity
  1923.         03h stick parity odd
  1924.         04h stick parity even
  1925.     BL = number of stop bits
  1926.         00h one stop bit
  1927.         01h two stop bits (1.5 if 5 bit word length)
  1928.     CH = word length
  1929.         00h 5 bits
  1930.         01h 6 bits
  1931.         02h 7 bits
  1932.         03h 8 bits
  1933.     CL = bps rate
  1934.         00h 110
  1935.         01h 150
  1936.         02h 300
  1937.         03h 600
  1938.         04h 1200
  1939.         05h 2400
  1940.         06h 4800
  1941.         07h 9600
  1942.         08h 19200
  1943.     DX = port number
  1944. Return: AX = port status code (see AH=00h)
  1945. ---------------------------------------------
  1946. INT 14 - FOSSIL - INITIALIZE DRIVER
  1947.     AH = 04h
  1948.     DX = port number
  1949.     optionally BX=4F50h
  1950.            ES:CX -> byte to be set upon ^C
  1951. Return: AX = 1954h (if successful)
  1952.     BL = maximum function number supported (excluding 7Eh and above)
  1953.     BH = revision of FOSSIL supported
  1954.     DTR is raised
  1955. Note:    the word at offset 6 in the interrupt handler contains 1954h, and the
  1956.     following byte contains the maximum function number supported
  1957. ---------------------------------------------
  1958. INT 14 - SERIAL I/O - EXTENDED COMMUNICATION PORT CONTROL (CONVERTIBLE,PS)
  1959.     AH = 05h
  1960.     AL = 00h read modem control register
  1961.           Return: BL = modem control register (see below)
  1962.               AH = status
  1963.     AL = 01h write modem control register
  1964.           BL = modem control register
  1965.           bit 0: data terminal ready
  1966.           bit 1: request to send
  1967.           bit 2: OUT1
  1968.           bit 3: OUT2
  1969.           bit 4: LOOP
  1970.           bits 5-7 reserved
  1971.           Return: AX = status
  1972.     DX = port number
  1973. ---------------------------------------------
  1974. INT 14 - FOSSIL - DEINITIALIZE DRIVER
  1975.     AH = 05h
  1976.     DX = port number
  1977. Return: none
  1978.     DTR is not affected
  1979. ---------------------------------------------
  1980. INT 14 - FOSSIL - RAISE/LOWER DTR
  1981.     AH = 06h
  1982.     DX = port
  1983.     AL = DTR state to be set
  1984.         00h = lower
  1985.         01h = raise
  1986. ---------------------------------------------
  1987. INT 14 - FOSSIL - RETURN TIMER TICK PARAMETERS
  1988.     AH = 07h
  1989. Return: AL = timer tick interrupt number
  1990.     AH = ticks per second on interrupt number in AL
  1991.     DX = approximate number of milliseconds per tick
  1992. ---------------------------------------------
  1993. INT 14 - FOSSIL - FLUSH OUTPUT BUFFER WAITING TILL ALL OUTPUT IS DONE
  1994.     AH = 08h
  1995.     DX = port number
  1996. ---------------------------------------------
  1997. INT 14 - FOSSIL - PURGE OUTPUT BUFFER THROWING AWAY ALL PENDING OUTPUT
  1998.     AH = 09h
  1999.     DX = port number
  2000. ---------------------------------------------
  2001. INT 14 - FOSSIL - PURGE INTPUT BUFFER THROWING AWAY ALL PENDING INPUT
  2002.     AH = 0Ah
  2003.     DX = port number
  2004. ---------------------------------------------
  2005. INT 14 - FOSSIL - TRANSMIT NO WAIT
  2006.     AH = 0Bh
  2007.     AL = character
  2008.     DX = port number
  2009. Return: AX = 0000h character not accepted
  2010.        = 0001h character accepted
  2011. ---------------------------------------------
  2012. INT 14 - FOSSIL - NON-DESTRUCTIVE READ AHEAD
  2013.     AH = 0Ch
  2014.     DX = port number
  2015. Return: AX = FFFFh character not available
  2016.     AX = 00xxh character xx available
  2017. ---------------------------------------------
  2018. INT 14 - FOSSIL - KEYBOARD READ WITHOUT WAIT
  2019.     AH = 0Dh
  2020. Return: AX = FFFFh character not available
  2021.        = xxyyh standard IBM-style scan code
  2022. ---------------------------------------------
  2023. INT 14 - FOSSIL - KEYBOARD READ WITH WAIT
  2024.     AH = 0Eh
  2025. Return: AX = xxyyh standard IBM-style scan code
  2026. ---------------------------------------------
  2027. INT 14 - FOSSIL - ENABLE/DISABLE FLOW CONTROL
  2028.     AH = 0Fh
  2029.     AL = bit mask describing flow control requested
  2030.         0: xon/xoff on transmit (watch for xoff while sending)
  2031.         1: CTS/RTS (CTS on transmit/RTS on receive)
  2032.         2: reserved
  2033.         3: xon/xoff on receive (send xoff when buffer near full)
  2034.         4-7: all 1
  2035.     DX = port number
  2036. ---------------------------------------------
  2037. INT 14 - FOSSIL - EXTENDED ^C/^K CHECKING AND TRANSMIT ON/OFF
  2038.     AH = 10h
  2039.     AL = bit mask
  2040.         0: enable/disable ^C/^K checking
  2041.         1: enable/disable the transmitter
  2042.     DX = port number
  2043. ---------------------------------------------
  2044. INT 14 - FOSSIL - SET CURRENT CURSOR LOCATION
  2045.     AH = 11h
  2046.     DH = row
  2047.     DL = column
  2048. Note: this is the same as INT 10/AH=02h
  2049. ---------------------------------------------
  2050. INT 14 - FOSSIL - READ CURRENT CURSOR LOCATION
  2051.     AH = 12h
  2052. Return: DH = row
  2053.     DL = column
  2054. Note: this is the same as INT 10/AH=03h
  2055. ---------------------------------------------
  2056. INT 14 - FOSSIL - SINGLE CHARACTER ANSI WRITE TO SCREEN
  2057.     AH = 13h
  2058.     AL = character
  2059. Note: should not be called if it is unsafe to call DOS
  2060. ---------------------------------------------
  2061. INT 14 - FOSSIL - ENABLE OR DISABLE WATCHDOG PROCESSING
  2062.     AH = 14h
  2063.     AL = 01h enable watchdog
  2064.          00h disable watchdog
  2065.     DX = port number
  2066. ---------------------------------------------
  2067. INT 14 - FOSSIL - WRITE CHARACTER TO SCREEN USING BIOS SUPPORT ROUTINES
  2068.     AH = 15h
  2069.     AL = character
  2070. ---------------------------------------------
  2071. INT 14 - FOSSIL - INSERT/DELETE FUNCTION FROM TIMER TICK CHAIN
  2072.     AH = 16h
  2073.     AL = function
  2074.         00h = delete
  2075.         01h = add
  2076.     ES:DX -> routine to call
  2077. Return: AX = 0000h successful
  2078.          0001h unsuccessful
  2079. ---------------------------------------------
  2080. INT 14 - FOSSIL - REBOOT SYSTEM
  2081.     AH = 17h
  2082.     AL = method
  2083.         00h = cold boot
  2084.         01h = warm boot
  2085. ---------------------------------------------
  2086. INT 14 - FOSSIL - READ BLOCK
  2087.     AH = 18h
  2088.     CX = maximum number of characters to transfer
  2089.     DX = port number
  2090.     ES:DI -> user buffer
  2091. Return: AX = number of characters transfered
  2092. ---------------------------------------------
  2093. INT 14 - FOSSIL - WRITE BLOCK
  2094.     AH = 19h
  2095.     CX = maximum number of characters to transfer
  2096.     DX = port number
  2097.     ES:DI -> user buffer
  2098. Return: AX = number of characters transfered
  2099. ---------------------------------------------
  2100. INT 14 - FOSSIL - BREAK BEGIN OR END
  2101.     AH = 1Ah
  2102.     AL = 00h stop sending 'break'
  2103.          01h start sending 'break'
  2104.     DX = port number
  2105. ---------------------------------------------
  2106. INT 14 - FOSSIL - RETURN INFORMATION ABOUT THE DRIVER
  2107.     AH = 1Bh
  2108.     DX = port number
  2109.     CX = size of user buffer
  2110.     ES:DI -> user buffer for driver info (see below)
  2111. Return: AX = number of characters transferred
  2112.  
  2113. Format of driver info:
  2114. Offset    Size    Description
  2115.  00h    WORD    size of structure in bytes
  2116.  02h    BYTE    FOSSIL spec driver conforms to
  2117.  03h    BYTE    revision level of this specific driver
  2118.  04h    DWORD    pointer to ASCIZ identification string
  2119.  08h    WORD    size of the input buffer
  2120.  0Ah    WORD    number of bytes left in buffer
  2121.  0Ch    WORD    size of the output buffer
  2122.  0Eh    WORD    number of bytes left in buffer
  2123.  10h    BYTE    width of screen
  2124.  11h    BYTE    length of screen
  2125.  12h    BYTE    actual baud rate, computer to modem
  2126. ---------------------------------------------
  2127. INT 14 - FOSSIL - INSTALL AN EXTERNAL APPLICATION FUNCTION
  2128.     AH = 7Eh
  2129.     AL = code assigned to external application
  2130.     ES:DX -> entry point
  2131. Return: AX = 1954h
  2132.     BL = code assigned to application (same as input AL)
  2133.     DH = 00h failed
  2134.          01h successful
  2135. ---------------------------------------------
  2136. INT 14 - FOSSIL - REMOVE AN EXTERNAL APPLICATION FUNCTION
  2137.     AH = 7Fh
  2138.     AL = code assigned to external application
  2139.     ES:DX -> entry point
  2140. Return: AX = 1954h
  2141.     BL = code assigned to application (same as input AL)
  2142.     DH = 00h failed
  2143.          01h successful
  2144. ---------------------------------------------
  2145. INT 15 - CASSETTE - TURN ON MOTOR (PC,Jr)
  2146.     AH = 00h
  2147. Return: CF set on error, AH = 86h if no cassette present
  2148. ---------------------------------------------
  2149. INT 15 - VMiX v2+ - INSTALLATION CHECK???
  2150.     AH = 00h
  2151. Return: DX = 0798h???
  2152. ---------------------------------------------
  2153. INT 15 - CASSETTE - TURN OFF MOTOR (PC,Jr)
  2154.     AH = 01h
  2155. Return: CF set on error, AH = 86h if no cassette present
  2156. ---------------------------------------------
  2157. INT 15 - VMiX - I/O CHANNEL OBJECT MANAGER
  2158.     AH = 01h
  2159.     STACK: WORD  object ID of requestor
  2160.            DWORD pointer to name of requested method
  2161.            WORD  arg1
  2162.            WORD  arg2
  2163.            WORD  arg3
  2164.            WORD  arg4
  2165. Return: DX:AX??? -> IRP structure or 0000h:0000h 
  2166. ---------------------------------------------
  2167. INT 15 - CASSETTE - READ DATA BLOCKS (PC,Jr)
  2168.     AH = 02h
  2169.     CX = count of bytes
  2170.     ES:BX -> data area
  2171. Return: CF set on error
  2172.     AH = status
  2173.         01h CRC error
  2174.         02h bad tape signals
  2175.         04h no data
  2176.         80h invalid command
  2177.         86h no cassette present
  2178.     DX = count of bytes read
  2179.     ES:BX = pointer past last byte read
  2180. ---------------------------------------------
  2181. INT 15 - VMiX - MEMORY OBJECT MANAGER
  2182.     AH = 02h
  2183.     STACK:    WORD    object ID of requestor
  2184.         DWORD    pointer to name of requested method
  2185.         WORD    arg1
  2186.         WORD    arg2
  2187.         WORD    arg3
  2188.         WORD    arg4
  2189.         WORD    arg5
  2190. Return: DX:AX??? = pointer to memory block
  2191. ---------------------------------------------
  2192. INT 15 - CASSETTE - WRITE DATA BLOCKS (PC,Jr)
  2193.     AH = 03h
  2194.     CX = count of bytes to write
  2195.     ES:BX -> data area
  2196. Return: CF set on error
  2197.        AH = status (see AH=02h)
  2198.     ES:BX = pointer past last byte written
  2199.     CX = 0
  2200. ---------------------------------------------
  2201. INT 15 - VMiX - PROMPTED CONSOLE INPUT
  2202.     AH = 03h
  2203.     STACK:    DWORD    pointer to ASCII prompt
  2204.         WORD    field outline character
  2205.         WORD    length of input field
  2206.         DWORD    address of pointer to input buffer
  2207.         WORD    number of characters input
  2208. Return: AX = length of input (input buffer is padded with blanks)
  2209. ---------------------------------------------
  2210. INT 15 - VMiX - VPRINTF
  2211.     AH = 04h
  2212.     STACK:    DWORD    control string
  2213.         DWORD    array of arguments
  2214. ---------------------------------------------
  2215. INT 15 - VMiX - GET PROCESS ID OF CURRENT PROCESS
  2216.     AH = 05h
  2217. Return: AX = process ID
  2218. ---------------------------------------------
  2219. INT 15 - VMiX - GET POINTER TO PROCESS CONTROL BLOCK
  2220.     AH = 06h
  2221.     STACK:    WORD    process ID
  2222. Return: DX:AX??? -> process control block
  2223. ---------------------------------------------
  2224. INT 15 - VMiX - GET POINTER TO OBJECT CONTROL BLOCK
  2225.     AH = 07h
  2226.     STACK:    WORD    object type
  2227. Return: DX:AX??? -> object control block
  2228. ---------------------------------------------
  2229. INT 15 - VMiX - GET CHANNEL CONTROL BLOCK
  2230.     AH = 08h
  2231.     STACK:    WORD    channel ID
  2232. Return: DX:AX??? -> channel control block
  2233. ---------------------------------------------
  2234. INT 15 - VMiX - GET ID OF QUEUED ELEMENT
  2235.     AH = 09h
  2236.     STACK:    WORD    queue ID (0 = process queue, 1 = object, 3 = type)
  2237.         WORD    subqueue ID
  2238. Return: AX = ID
  2239. ---------------------------------------------
  2240. INT 15 - VMiX - GET ID OF NEXT QUEUED ELEMENT
  2241.     AH = 0Ah
  2242.     STACK:    WORD    queue ID (0 = process queue, 1 = object, 3 = type)
  2243.         WORD    ID of current element in queue chain
  2244. Return: AX = ID of next element
  2245. ---------------------------------------------
  2246. INT 15 - VMiX - GET TOTAL NUMBER OF ACTIVE PROCESSES
  2247.     AH = 0Bh
  2248. Return: AX = number of active processes
  2249. ---------------------------------------------
  2250. INT 15 - VMiX - GET POINTER TO PROCESS TSS STACK
  2251.     AH = 0Ch
  2252.     STACK:    WORD    process ID
  2253. Return: DX:AX??? -> TSS stack store
  2254. ---------------------------------------------
  2255. INT 15 - VMiX - START A CHILD PROCESS JOB SHELL
  2256.     AH = 0Dh
  2257.     STACK:    DWORD    ASCIZ string starting with requested I/O channel and
  2258.             followed by standard VMiX shell command string
  2259. Return: AX = status
  2260. ---------------------------------------------
  2261. INT 15 - VMiX - TERMINATE PROCESS
  2262.     AH = 0Eh
  2263.     STACK:    WORD    process ID
  2264. Return: AX = status
  2265. ---------------------------------------------
  2266. INT 15 - SYSTEM - FORMAT UNIT PERIODIC INTERRUPT (PS ESDI drives only)
  2267.     AH = 0Fh
  2268.     AL = phase code
  2269.         00h reserved
  2270.         01h surface analysis
  2271.         02h formatting
  2272. Return: CF clear if formatting should continue, set if it should terminate
  2273. Note: called during ESDI drive formatting after each cylinder is completed
  2274. ---------------------------------------------
  2275. INT 15 - VMiX - GET KEY FIELD OF QUEUED ELEMENT
  2276.     AH = 0Fh
  2277.     STACK:    WORD    queue ID (0 = process queue, 1 = object q, 3 = type q)
  2278.         WORD    ID of element in queue chain
  2279. Return: AX = key
  2280. ---------------------------------------------
  2281. INT 15 - VMiX - EXECUTE FUNCTION IN PROTECTED MODE
  2282.     AH = 10h
  2283.     STACK:    DWORD    pointer to function
  2284.           N    WORDs    function args
  2285. Return: ???
  2286. ---------------------------------------------
  2287. INT 15 - TopView - "PAUSE" - GIVE UP CPU TIME
  2288.     AX = 1000h
  2289. Return: after other processes run
  2290. ---------------------------------------------
  2291. INT 15 - TopView - "GETMEM" - ALLOCATE "SYSTEM" MEMORY
  2292.     AX = 1001h
  2293.     BX = number of bytes to allocate
  2294. Return: ES:DI -> block of memory
  2295. ---------------------------------------------
  2296. INT 15 - TopView - "PUTMEM" - DEALLOCATE "SYSTEM" MEMORY
  2297.     AX = 1002h
  2298.     ES:DI -> previously allocated block
  2299. Return: block freed
  2300. ---------------------------------------------
  2301. INT 15 - TopView - "PRINTC" - DISPLAY CHARACTER/ATTRIBUTE ON SCREEN
  2302.     AX = 1003h
  2303.     BH = attribute
  2304.     BL = character
  2305.     DX = segment of object handle for window
  2306. Note: BX=0 does not display anything, it only positions the hardware cursor
  2307. ---------------------------------------------
  2308. INT 15 - TopView - UNIMPLEMENTED IN DV 2.x
  2309.     AH = 10h
  2310.     AL = 04h thru 12h
  2311. Return: pops up "Programming error" window in DV 2.x
  2312. ---------------------------------------------
  2313. INT 15 - TopView - "GETBIT" - DEFINE A 2ND-LEVEL INTERRUPT HANDLER
  2314.     AX = 1013h
  2315.     ES:DI -> FAR service routine
  2316. Return: BX = bit mask indicating which bit was allocated
  2317.          0000h if no more bits available
  2318. ---------------------------------------------
  2319. INT 15 - TopView - "FREEBIT" - UNDEFINE A 2ND-LEVEL INTERRUPT HANDLER
  2320.     AX = 1014h
  2321.     BX = bit mask from INT 15/AX=1013h
  2322. ---------------------------------------------
  2323. INT 15 - TopView - "SETBIT" - SCHEDULE ONE OR MORE 2ND-LEVEL INTERRUPTS
  2324.     AX = 1015h
  2325.     BX = bit mask for interrupts to post
  2326. Return: indicated routines will be called: (DV 2.0x) at next task switch
  2327.                        (DV 2.2x) immediately
  2328. ---------------------------------------------
  2329. INT 15 - TopView - "ISOBJ" - VERIFY OBJECT HANDLE
  2330.     AX = 1016h
  2331.     ES:DI = possible object handle
  2332. Return: BX = FFFFh if ES:DI is a valid object handle
  2333.          0000h if ES:DI is not
  2334. ---------------------------------------------
  2335. INT 15 - TopView - UNIMPLEMENTED IN DV 2.x
  2336.     AX = 1017h
  2337. Return: pops up "Programming error" window in DV 2.x
  2338. ---------------------------------------------
  2339. INT 15 - TopView - "LOCATE" - FIND WINDOW AT A GIVEN SCREEN LOCATION
  2340.     AX = 1018h
  2341.     BH = column
  2342.     BL = row
  2343.     ES = segment of object handle for window below which to search
  2344.          0000h = start search with topmost window
  2345. Return: ES = segment of object handle for window which is visible at the
  2346.          indicated position, or covered by indicated window
  2347. ---------------------------------------------
  2348. INT 15 - TopView - "SOUND" - MAKE TONE
  2349.     AX = 1019h
  2350.     BX = frequency in Hertz
  2351.     CX = duration in clock ticks (18.2 ticks/sec)
  2352. Return: immediately, tone continues to completion
  2353. Notes: if another tone is already playing, the new tone does not start until
  2354.        completion of the previous one.    In DV 2.00, it is possible to enqueue
  2355.        about 32 tones before the process is blocked until a note completes.
  2356.        in DV 2.00, the lowest tone allowed is 20 Hz
  2357. ---------------------------------------------
  2358. INT 15 - TopView - "OSTACK" - SWITCH TO TASK'S INTERNAL STACK
  2359.     AX = 101Ah
  2360. Return: stack switched
  2361. ---------------------------------------------
  2362. INT 15 - TopView - "BEGINC" - BEGIN CRITICAL REGION
  2363.     AX = 101Bh
  2364. Return: task-switching temporarily disabled
  2365. Note: will not task-switch until END CRITICAL REGION (AX = 101Ch) called
  2366. ---------------------------------------------
  2367. INT 15 - TopView - "ENDC" - END CRITICAL REGION
  2368.     AX = 101Ch
  2369. Return: task-switching enabled
  2370. ---------------------------------------------
  2371. INT 15 - TopView - "STOP" - STOP TASK
  2372.     AX = 101Dh
  2373.     ES = segment of object handle for task to be stopped
  2374.          (== handle of main window for that task)
  2375. Return: indicated task will no longer get CPU time
  2376. Note: at least in DV 2.00, this function is ignored unless the indicated task
  2377.       is the current task.
  2378. ---------------------------------------------
  2379. INT 15 - TopView - "START" - START TASK
  2380.     AX = 101Eh
  2381.     ES = segment of object handle for task to be started
  2382.          (== handle of main window for that task)
  2383. Return: indicated task is started up again
  2384. ---------------------------------------------
  2385. INT 15 - TopView - "DISPEROR" - POP-UP ERROR WINDOW
  2386.     AX = 101Fh
  2387.     BX = bit fields
  2388.          bits 0-12: number of characters to display
  2389.          bits 13,14: which mouse button may be pressed to remove window
  2390.              00 = either
  2391.              01 = left
  2392.              10 = right
  2393.              11 = either
  2394.          bit 15: beep if 1
  2395.     DS:DI -> text of message
  2396.     CH = width of error window (0 = default)
  2397.     CL = height of error window (0 = default)
  2398.     DX = segment of object handle
  2399. Return: BX = status: 1 = left button, 2 = right, 27 = ESC pressed
  2400. Note: window remains on-screen until ESC or indicated mouse button is pressed
  2401. ---------------------------------------------
  2402. INT 15 - TopView - UNIMPLEMENTED IN DV 2.0x
  2403.     AX = 1020h
  2404. Return: pops up "Programming error" window in DV 2.0x
  2405. ---------------------------------------------
  2406. INT 15 - TopView - "PGMINT" - INTERRUPT ANOTHER TASK
  2407.     AX = 1021h
  2408.     BX = segment of object handle for task to interrupt
  2409.     DX:CX -> FAR routine to jump to next time task is run
  2410. Return: nothing
  2411. Note: the current ES, DS, SI, DI, and BP are passed to the FAR routine
  2412. ---------------------------------------------
  2413. INT 15 - TopView - "GETVER" - GET VERSION
  2414.     AX = 1022h
  2415.     BX = 0
  2416. Return: BX nonzero, TopView or compatible loaded
  2417.     (BL = major version, BH = minor version)
  2418. Notes: TaskView returns BX = 0001h, DESQview 2.0 returns BX = 0A01h
  2419. ---------------------------------------------
  2420. INT 15 - TopView - "POSWIN" - POSITION WINDOW
  2421.     AX = 1023h
  2422.     BX = segment of object handle for parent window within which to
  2423.          position the window (0 = full screen)
  2424.     ES = segment of object handle for window to be positioned
  2425.     DL = bit flags
  2426.          bits 0,1: horizontal position
  2427.         00 = current
  2428.         01 = center
  2429.         10 = left
  2430.         11 = right
  2431.          bits 2,3: vertical position
  2432.         00 = current
  2433.         01 = center
  2434.         10 = top
  2435.         11 = bottom
  2436.          bit 4: don't redraw screen if set
  2437.          bits 5-7 not used
  2438.     CH = number of columns to offset from position specified by DL
  2439.     CL = number of rows to offset from position specified by DL
  2440. Return: nothing
  2441. ---------------------------------------------
  2442. INT 15 - TopView - "GETBUF" - GET VIRTUAL SCREEN INFO
  2443.     AX = 1024h
  2444.     BX = segment of object handle for window
  2445.           (0 = use default)
  2446. Return: ES:DI -> virtual screen
  2447.     CX = size of virtual screen in bytes
  2448.     DL = 00h text screen
  2449.          01h graphics screen
  2450. ---------------------------------------------
  2451. INT 15 - TopView - "USTACK" - SWITCH BACK TO USER'S STACK
  2452.     AX = 1025h
  2453. Return: stack switched back
  2454. Note: call only after INT 15h/AX=101Ah
  2455. ---------------------------------------------
  2456. INT 15 - DESQview (TopView???) - UNIMPLEMENTED IN DV 2.x
  2457.     AH = 10h
  2458.     AL = 26h thru 2Ah
  2459. Return: pops up "Programming error" window in DV 2.x
  2460. ---------------------------------------------
  2461. INT 15 - DESQview 2.0 (TopView???) - "POSTTASK" - AWAKEN TASK
  2462.     AX = 102Bh
  2463.     BX = segment of object handle for task
  2464. Return: nothing
  2465. ---------------------------------------------
  2466. INT 15 - DESQview 2.0 (TopView???) - START NEW APPLICATION IN NEW PROCESS
  2467.     AX = 102Ch
  2468.     ES:DI -> contents of .PIF/.DVP file (see below)
  2469.     BX = size of .PIF/.DVP info
  2470. Return: BX = segment of object handle for new task
  2471.          0000h on error
  2472.  
  2473. Format of .PIF/.DVP file:
  2474. Offset    Size    Description
  2475.  00h    WORD    reserved (0)
  2476.  02h 30 BYTEs    program title (blank-padded)
  2477.  20h    WORD    maximum memory to allocate to partition in K
  2478.  22h    WORD    minimum memory required in K
  2479.  24h 64 BYTEs    ASCIZ program pathname
  2480.  64h    BYTE    default drive letter ('A',...)
  2481.  65h 64 BYTEs    ASCIZ default directory name
  2482.  A5h 64 BYTEs    ASCIZ program parameters
  2483.  E5h    BYTE    initial screen mode (0-7)
  2484.  E6h    BYTE    number of text pages used
  2485.  E7h    BYTE    number of first interrupt to save
  2486.  E8h    BYTE    number of last interrupt to save
  2487.  E9h    BYTE    rows in virtual screen buffer
  2488.  EAh    BYTE    columns in virtual screen buffer
  2489.  EBh    BYTE    initial window position, row
  2490.  ECh    BYTE    initial window position, column
  2491.  EDh    WORD    system memory in K
  2492.  EFh 64 BYTEs    ASCIZ shared program name
  2493. 12Fh 64 BYTEs    ASCIZ shared program data file
  2494. 16Fh    BYTE    flags1
  2495.         bit 7: writes text directly to screen
  2496.         bit 6: runs in foreground only
  2497.         bit 5: uses math coprocessor
  2498.         bit 4: accesses system keyboard buffer directly
  2499.         bits 3-1: reserved (0)
  2500.         bit 0: swappable
  2501. 170h    BYTE    flags2
  2502.         bit 6: uses command-line parameters in field at A5h
  2503.         bit 5: swaps interrupt vectors
  2504. ---information unique to .DVP files---
  2505. 171h  2 BYTEs    keys to use on open menu
  2506. 173h    WORD    size of script buffer in bytes
  2507. 175h    WORD    automatically give up CPU after this many tests for keyboard
  2508.         input in one clock tick (0 = never)
  2509. 177h    BYTE    nonzero = "uses own colors"
  2510. 178h    BYTE    nonzero if application swappable
  2511. 179h  3 BYTEs    reserved (0)
  2512. 17Ch    BYTE    nonzero to automatically close on exit
  2513. 17Dh    BYTE    nonzero if copy-protect floppy is required
  2514. ---information unique to DESQview 2.0+---
  2515. 17Eh    BYTE    .DVP version number
  2516.         00h DESQview 1.2+
  2517.         01h DESQview 2.0+
  2518.         02h DESQview 2.2+
  2519. 17Fh    BYTE    reserved (0)
  2520. 180h    BYTE    initial number of rows in physical window
  2521. 181h    BYTE    initial number of columns in physical window
  2522. 182h    WORD    maximum expanded memory to allow, in K
  2523. 184h    BYTE    flags3
  2524.         bit 7: automatically assign window position
  2525.         bit 5: maximum memory value has been specified
  2526.         bit 4: disallow "Close" command
  2527.         bit 3: foreground-only when doing graphics
  2528.         bit 2: don't virtualize
  2529. 185h    BYTE    keyboard conflict level (0-4)
  2530. 186h    BYTE    number of graphics pages used
  2531. 187h    WORD    extra system memory size
  2532. 189h    BYTE    initial screen mode (FFh = default)
  2533. ---information unique to DESQview 2.2+---
  2534. 18Ah    BYTE    serial port usage
  2535.         FFh uses all serial ports
  2536.         00h no serial ports
  2537.         01h only COM1
  2538.         02h only COM2
  2539. 18Bh    BYTE    flags4
  2540.         bit 7: automatically close application on exit if .COM or .EXE
  2541.             specified
  2542.         bit 6: swappable if not using serial ports
  2543.         bit 3: virtualize text
  2544.         bit 2: virtualize graphics
  2545.         bit 1: share CPU when foreground
  2546.         bit 0: share EGA when foreground and zoomed
  2547. 18Ch    BYTE    protection level for 386 machines
  2548. 18Dh 19 BYTEs    reserved (0)
  2549. ---------------------------------------------
  2550. INT 15 - DESQview 2.0 - KEYBOARD MOUSE CONTROL
  2551.     AX = 102Dh
  2552.     BL = subfunction
  2553.          00h determine whether using keyboard mouse
  2554.         Return: BL = 00h using real mouse
  2555.                  01h using keyboard mouse
  2556.          01h turn keyboard mouse on
  2557.          02h turn keyboard mouse off
  2558. ---------------------------------------------
  2559. INT 15 - TopView commands
  2560.     AH = 11h
  2561.     AL = various
  2562. Note: in DESQview 2.x, these function calls are identical to AH=DEh, so
  2563.       see those below
  2564. ---------------------------------------------
  2565. INT 15 - VMiX - EXECUTE SHELL SYSTEM COMMANDS
  2566.     AH = 11h
  2567.     STACK:    DWORD    pointer to ASCIZ string containing and VMiX shell
  2568.             request (max len = 127)
  2569. Return: AX = status
  2570. ---------------------------------------------
  2571. INT 15 - DESQview 2.2 - "ASSERTMAP" - GET/SET MAPPING CONTEXT
  2572.     AX = 1117h
  2573.     BX = 0000h    get current mapping context without setting
  2574.          nonzero    set new mapping context
  2575. Return: BX = mapping context in effect before call
  2576. Notes:    this function differs from AX = DE17h
  2577.     mapping contexts determine conventional-memory addressability; setting
  2578.     a mapping context ensures that the associated program and data areas
  2579.     are in memory for access.  Usable by drivers, TSRs and shared programs.
  2580.     Caller need not be running under DESQview
  2581. ---------------------------------------------
  2582. INT 15 - DESQview - XDV.COM - INSTALLATION CHECK
  2583.     AX = 11DEh
  2584. Return: CF clear if installed
  2585.         AX = segment at which XDV is located
  2586. ---------------------------------------------
  2587. INT 15 - VMiX - PUT PROCESS TO SLEEP
  2588.     AH = 12h
  2589.     STACK:    WORD    process ID
  2590. Return: AX = status
  2591. ---------------------------------------------
  2592. INT 15 - TopView - SEND MESSAGE - "HANDLE" - RETURN OBJECT HANDLE
  2593.     AH = 12h
  2594.     BH = 00h
  2595.     BL = which handle to return
  2596.         00h handle in DWORD on top of stack
  2597.         01h current task's window handle
  2598.         02h given task's mailbox handle (task's handle on stack)
  2599.         03h current task's mailbox handle
  2600.         04h given task's keyboard handle (task's handle on stack)
  2601.         05h current task's keyboard object handle
  2602.         06h given task's OBJECTQ handle (task's handle on stack)
  2603.         07h current task's OBJECTQ handle
  2604.         08h   \
  2605.           thru > return 0000:0000
  2606.         10h   /
  2607. Return: DWORD on top of stack is object handle
  2608. ---------------------------------------------
  2609. INT 15 - TopView - SEND MESSAGE - "NEW" - CREATE NEW OBJECT
  2610.     AH = 12h
  2611.     BH = 01h
  2612.     BL = object
  2613.         00h (DV 2.0x only) handle is DWORD on top of stack
  2614.         01h (DV 2.0x only) use task's window handle
  2615.         02h (DV 2.0x only) given task's mailbox (task's handle on stack)
  2616.         03h (DV 2.0x only) current task's mailbox
  2617.         04h (DV 2.0x only) given task's keyboard (task's handle on stack)
  2618.         05h (DV 2.0x only) current task's keyboard object
  2619.         08h WINDOW class
  2620.         09h MAILBOX class
  2621.         0Ah KEYBOARD class
  2622.         0Bh TIMER object (counts down 32-bit time in 10ms increments)
  2623.         0Fh POINTER object
  2624.         10h PANEL object
  2625.     STACK: (if window object or WINDOW class)
  2626.            DWORD address to jump to (no new task if high word == 0)
  2627.            DWORD (reserved) 0 = non-task window, FFFFh = task window
  2628.            DWORD bytes for task's private stack (FFFFh == default of 0100h)
  2629.            DWORD bytes system memory allocation (0 == none, -1 == default)
  2630.            DWORD window size, columns
  2631.            DWORD window size, rows
  2632.            DWORD length of window title
  2633.            DWORD address of window title
  2634. Return: DWORD on top of stack is new object handle
  2635. Note: if a new task is created, it is started with
  2636.       AX = BX = CX = SI = DI = BP = 0
  2637.       DX = segment of parent's object handle
  2638.       DS = ES = SS = segment of private stack (and new task's object handle)
  2639. ---------------------------------------------
  2640. INT 15 - TopView - SEND MESSAGE - "FREE" - FREE AN OBJECT
  2641.     AH = 12h
  2642.     BH = 02h
  2643.     BL = object
  2644.         00h handle in DWORD on top of stack
  2645.         window: close window and free
  2646.         timer: free timer
  2647.         panel: free panel object
  2648.         pointer: free pointer
  2649.         01h task's window handle - kills task, never returns
  2650.         02h given task's mailbox (task's handle on top of stack)
  2651.         03h current task's mailbox
  2652.         04h given task's keyboard (task's handle on top of stack)
  2653.         05h current task's keyboard object
  2654. ---------------------------------------------
  2655. INT 15 - TopView - SEND MESSAGE - "DIR" - GET PANEL FILE DIRECTORY
  2656.     AH = 12h
  2657.     BX = 0300h
  2658.     STACK: DWORD handle of panel object
  2659. Return: STACK: DWORD length of directory
  2660.            DWORD address of directory
  2661.  
  2662. Format of panel file:
  2663. Offset    Size    Descriptoin
  2664.  00h  2 BYTEs    C0h C3h
  2665.  02h    BYTE    number of panels in file
  2666.  03h    for each panel in file:
  2667.         8 BYTEs  blank-padded panel name
  2668.           DWORD  panel offset in file
  2669.           WORD   panel length
  2670.     data for panels (each consists of one or more window/query/manager
  2671.     streams)
  2672.         first byte of each panel must be 1Bh, fifth byte must be E5h
  2673. ---------------------------------------------
  2674. INT 15 - TopView - SEND MESSAGE - "ADDR" - GET OBJECT HANDLE
  2675.     AH = 12h
  2676.     BH = 03h
  2677.     BL = object
  2678.         00h handle in DWORD on top of stack
  2679.         02h sender of last msg read from mailbox (task's handle on stack)
  2680.         03h sender of last msg read from current task's mailbox
  2681. Return: DWORD on stack is handle
  2682. ---------------------------------------------
  2683. INT 15 - TopView - SEND MESSAGE - "READ" - WAIT FOR TIMER TO EXPIRE
  2684.     AH = 12h
  2685.     BX = 0400h
  2686.     STACK: DWORD timer's handle
  2687. Return: STACK: DWORD time in 1/100 sec since midnight when timer expires
  2688. ---------------------------------------------
  2689. INT 15 - TopView - SEND MESSAGE - "READ" - GET NEXT RECORD
  2690.     AH = 12h
  2691.     BH = 04h
  2692.     BL = object
  2693.         00h handle is DWORD on top of stack
  2694.         window: read next logical line
  2695.         mailbox: wait for and get next message
  2696.         pointer: wait for and get next message
  2697.         01h read the next logical line from task's default window
  2698.         02h get next message from mailbox (task's handle on top of stack)
  2699.         03h get next message from current task's mailbox
  2700.         04h get the next input from keyboard (handle on top of stack)
  2701.         05h get the next input from task's default keyboard
  2702.         06h wait for input from any object in OBJECTQ (handle on stack)
  2703.         07h wait for input from any object in task's default OBJECTQ
  2704. Return: STACK: (if objectq) DWORD handle of object with input
  2705.            (otherwise)  DWORD number of bytes
  2706.                 DWORD address
  2707. ---------------------------------------------
  2708. INT 15 - TopView - SEND MESSAGE - "APPLY" - WRITE PANEL TO WINDOW
  2709.     AH = 12h
  2710.     BX = 0400h
  2711.     STACK: DWORD handle of panel object
  2712.            DWORD window's handle or 0
  2713.            DWORD length of panel name
  2714.            DWORD pointer to panel name
  2715. Return: STACK: DWORD handle of created keyboard or 0
  2716.            DWORD handle of window which was used
  2717. Notes: status of APPLY may be checked with STATUS message
  2718.        panel MUST have the following format
  2719.      first byte must be 1Bh (i.e. must start with a stream)
  2720.      first opcode in stream must be E5h
  2721.        single byte arg of opcode is interpreted thus:
  2722.           bit 7  \    11 means new window created
  2723.           bit 6  /    01 means existing window used
  2724.           bit 5 if set, create a new keyboard and put in field mode
  2725.           bit 4 if set and bit 5 set, make new keyboard active
  2726. --------------------------------------------
  2727. INT 15 - TopView - SEND MESSAGE - "WRITE" - WRITE TO OBJECT
  2728.     AH = 12h
  2729.     BH = 05h
  2730.     BL = object
  2731.         00h handle is DWORD on top of stack
  2732.         timer: start timer to end at a specified time
  2733.         pointer: move pointer icon to specified position
  2734.         02h send message by value/status=0 to mbox (task's handle on stack)
  2735.         03h send message by value/status=0 to current task's mailbox
  2736.         04h add input buffer to KEYBOARD queue (handle on top of stack)
  2737.         05h add input buffer to task's default KEYBOARD queue
  2738.         06h add an object to OBJECTQ (handle on top of stack)
  2739.         07h add an object to task's default OBJECTQ
  2740.     STACK: (if mailbox)  DWORD length
  2741.                  DWORD address
  2742.            (if keyboard) DWORD status (such as scan code)
  2743.                  DWORD length
  2744.                  DWORD address
  2745.            (if objectq)  DWORD handle of object to add
  2746.            (if timer)    DWORD 1/100ths seconds since midnight (actually
  2747.                    only accurate to 1/18 sec)
  2748.            (if pointer)  DWORD column relative to origin of window
  2749.                  DWORD row relative to origin of window
  2750. ---------------------------------------------
  2751. INT 15 - TopView - SEND MESSAGE - "WRITE" - WRITE STRING TO WINDOW
  2752.     AH = 12h
  2753.     BH = 05h
  2754.     BL = object
  2755.         00h DWORD on top of stack is window handle
  2756.         01h write string to task's default window
  2757.     STACK: DWORD object handle if handle passed on stack
  2758.            DWORD total length of string (high word == 0)
  2759.            DWORD address of string to display
  2760. Note: service routine will pop stack
  2761. Return: indicated actions performed
  2762.     a. non-control characters are displayed
  2763.     b. CR/LF/BS/Tab cause the usual cursor movement
  2764.     c. ESC starts a data structure with additional commands
  2765.  
  2766. Data Structure:
  2767.     MAGIC  DB  1Bh
  2768.     MODE   DB  ?   ; 00h, 01h, 10h, 14h-1Fh legal
  2769.     LENGTH DW  ?   ; length of remainder in bytes
  2770.     var-length fields follow, each an OPCODE followed by
  2771.          zero or more args
  2772.  
  2773. MODE 00h (set or display values) "WINDOW STREAM"
  2774.     Opcodes:args
  2775.     00h  display 20h blanks with the default attribute
  2776.     01h-1Fh display OPCODE blanks with the default attribute
  2777.     20h  display char with default attribute 20h times
  2778.          BYTE char to repeat
  2779.     21h-3Fh display char with default attribute OPCODE-20h times
  2780.          BYTE char to repeat
  2781.     40h  display 20h blanks with specified attribute
  2782.          BYTE attribute of blanks
  2783.     41h-5Fh display OPCODE-40h blanks with specified attribute
  2784.          BYTE attribute of blanks
  2785.     60h  display next 20h characters
  2786.          20h BYTES characters to display
  2787.     61h-7Fh display next OPCODE-60h characters
  2788.          N BYTES characters to display
  2789.     80h-87h  display N blanks with default attribute
  2790.          BYTE low 8 bits of 11-bit count (high 3 in low 3 bits of OPCODE)
  2791.               [000h means 800h]
  2792.     88h-8Fh display N copies of the character
  2793.          BYTE low 8 bits of 11-bit count (high 3 in low 3 bits of OPCODE)
  2794.               [000h means 800h]
  2795.          BYTE character to repeat
  2796.     90h-97h  display N blanks with specified attribute
  2797.          BYTE low 8 bits of 11-bit length (high 3 in low 3 bits of OPCODE)
  2798.               [000h means 800h]
  2799.          BYTE attribute
  2800.     98h-9FH  display string at logical cursor pos
  2801.          BYTE low 8 bits of 11-bit length (high 3 in low 3 bits of OPCODE)
  2802.               [000h means 800h]
  2803.          N BYTES string to display
  2804.     A0h  set logical cursor row
  2805.          BYTE row number (0 is top)
  2806.     A1h  set logical cursor column
  2807.          BYTE column number (0 is leftmost)
  2808.     A2h  set top edge of scrolling region
  2809.          BYTE row
  2810.     A3h  set left edge of scrolling region
  2811.          BYTE column
  2812.     A4h  set row of physical window position
  2813.          BYTE line
  2814.     A5h  set column of physical window position
  2815.          BYTE column
  2816.     A6h  set height of physical window
  2817.          BYTE #rows
  2818.     A7h  set width of physical window
  2819.          BYTE #columns
  2820.     A8h  set viewport row
  2821.          BYTE row
  2822.     A9h  set viewport column
  2823.          BYTE column
  2824.     AAh  set virtual screen height
  2825.          BYTE rows
  2826.     ABh  set virtual screen width
  2827.          BYTE columns
  2828.     ACh-AEh  unused
  2829.     AFh  set compatible/preferred video modes
  2830.          BYTE compatibility/preference mask
  2831.         bit 7    compatible with monochrome
  2832.         bit 6    compatible with color text, EGA/VGA graphics
  2833.         bit 5    compatible with medium-resolution CGA graphics
  2834.         bit 4    compatible with high-resolution CGA graphics
  2835.         bit 3    prefer monochrome
  2836.         bit 2    prefer color text, EGA/VGA graphics
  2837.         bit 1    prefer medium-resolution CGA graphics
  2838.         bit 0    prefer high-resolution CGA graphics
  2839.     B0h  move logical cursor down
  2840.          BYTE #rows (signed, negative values move up)
  2841.     B1h  move logical cursor right
  2842.          BYTE #cols (signed, negative values move left)
  2843.     B2h  shift top edge of scrolling region
  2844.          BYTE #rows (signed)
  2845.     B3h  shift left edge of scrolling region
  2846.          BYTE #cols (signed)
  2847.     B4h  shift window down
  2848.          BYTE #lines (signed)
  2849.     B5h  shift window right
  2850.          BYTE #columns (signed)
  2851.     B6h  expand physical window vertically
  2852.          BYTE #lines (signed)
  2853.     B7h  expand physical window horizontally
  2854.          BYTE #columns (signed)
  2855.     B8h  adjust viewport row
  2856.          BYTE #rows (signed)
  2857.     B9h  adjust viewport column
  2858.          BYTE #columns (signed)
  2859.     BAh  adjust virtual screen height
  2860.          BYTE #rows to increase (signed)
  2861.     BBh  adjust virtual screen width
  2862.          BYTE #cols to increase (signed)
  2863.     BCh-BFh  unused
  2864.     C0h  set logical cursor position
  2865.          BYTE row number (0 is top border)
  2866.          BYTE column number (0 is left border)
  2867.     C1h  set top left corner of scrolling region
  2868.          BYTE row
  2869.          BYTE column
  2870.     C2h  set window pos
  2871.          BYTE upper left row (no top border if 0)
  2872.          BYTE upper left column (no left border if 0)
  2873.     C3h  set current window size
  2874.          BYTE #rows
  2875.          BYTE #cols
  2876.     C4h  set upper left corner of viewport (portion of virtual screen
  2877.          displayed in window)
  2878.          BYTE row
  2879.          BYTE column
  2880.     C5h  set size of virtual screen
  2881.          BYTE #rows
  2882.          BYTE #cols
  2883.     C6h  unused
  2884.     C7h  unused
  2885.     C8h  set logical cursor relative to current position
  2886.          BYTE number of rows to move down (signed)
  2887.          BYTE number of columns to move right (signed)
  2888.     C9h  shift top left corner of scrolling region
  2889.          BYTE #rows (signed)
  2890.          BYTE #cols (signed)
  2891.     CAh  set window pos relative to current position
  2892.          BYTE number of rows to shift down (signed)
  2893.          BYTE number of columns to shift right (signed)
  2894.     CBh  set window size relative to current size
  2895.          BYTE number of rows to expand (signed)
  2896.          BYTE number of cols to expand (signed)
  2897.     CCh  shift viewport relative to current position
  2898.          BYTE rows to shift (signed)
  2899.          BYTE cols to shift (signed)
  2900.     CDh  resize virtual screen
  2901.          BYTE #rows to expand (signed)
  2902.          BYTE #cols to expand (signed)
  2903.     CEh  scroll text when using E8h-EBh/F8h-FBh opcodes (default)
  2904.     CFh  scroll attributes when using  E8h-EBh/F8h-FBh opcodes
  2905.     D0h  allow window frame to extend beyond screen
  2906.     D1h  always display a complete frame, even if window extends beyond 
  2907.          edge of screen
  2908.     D2h  allow DV to change colors on video mode switch (default)
  2909.     D3h  application changes colors
  2910.     D4h  window is visible
  2911.     D5h  window is hidden
  2912.     D6h  window has frame
  2913.     D7h  window unframed
  2914.     D8h  read characters from window (default)
  2915.     D9h  read attributes from window
  2916.     DAh  use logical attributes, which may be remapped
  2917.         attributes
  2918.            1 normal text
  2919.            2 highlighted normal text
  2920.            3 help text
  2921.            4 highlighted help text
  2922.            5 error message
  2923.            6 highlighted error message
  2924.            7 emphasized text
  2925.            8 marked text
  2926.            9-16 are reverse video versions of 1-8
  2927.     DBh  use physical attributes for characters
  2928.     DCh  enable special actions for control characters (default)
  2929.     DDh  disable special control char handling, all chars displayable by
  2930.          BIOS TTY call
  2931.     DEh  write both character and attribute (default)
  2932.     DFh  write character only, leave attribute untouched
  2933.     E0h  repeat following commands
  2934.          BYTE number of times
  2935.     E1h  end of commands to repeat, start repeating them
  2936.     E2h  set color
  2937.          BYTE color
  2938.     E3h  clear virtual screen
  2939.     E4h  redraw window
  2940.     E5h  select menu style
  2941.          BYTE style
  2942.         bits 5,4 = 01 use two-letter menu entries for remainder of
  2943.           this stream
  2944.     E5h  (panel file only)
  2945.          BYTE modifier
  2946.         bits 7,6 = 11 panel goes in new window
  2947.              = 01 panel uses existing window
  2948.         bit 5 = 1 create new keyboard in field mode
  2949.         bit 4 = 1 make newly-created keyboard active
  2950.         bit 3 reserved
  2951.         bit 2 = 1 stream defined exclusive input window (DV 2.2)
  2952.         bit 1 reserved
  2953.         bit 0 reserved
  2954.     E6h  create new window and perform rest of manipulations in new window
  2955.          BYTE number of rows
  2956.          BYTE number of columns
  2957.          Return: DWORD object handle returned on stack at end
  2958.     E7h  unused
  2959.     E8h  scroll area up (top left corner defined by opcode C1h)
  2960.          BYTE height
  2961.          BYTE width
  2962.     E9h  scroll area down (top left corner defined by opcode C1h)
  2963.          BYTE height
  2964.          BYTE width
  2965.     EAh  scroll area left (top left corner defined by opcode C1h)
  2966.          BYTE height
  2967.          BYTE width
  2968.     EBh  scroll area right (top left corner defined by opcode C1h)
  2969.          BYTE height
  2970.          BYTE width
  2971.     ECh  set logical attributes for window contents
  2972.          BYTE video modes command applies to
  2973.         bit 7    monochrome
  2974.         bit 6    color text, EGA/VGA graphics
  2975.         bit 5    medium-resolution CGA graphics
  2976.         bit 4    high-resolution CGA graphics
  2977.          BYTE which attributes to set
  2978.         bit 7  if set, copy single following byte to indicated attrs
  2979.         bits 4-6  # of first attribute to change - 1
  2980.         bits 0-3  # of consecutive attributes to change
  2981.          N BYTEs new attributes
  2982.     EDh  set logical attributes for window frame
  2983.          BYTE video modes command applies to (see opcode ECh)
  2984.          BYTE which attributes to set
  2985.         bit 7  if set, copy single following byte to indicated attrs
  2986.         bits 4-6  # of first attribute to change - 1
  2987.         bits 0-3  # of consecutive attributes to change
  2988.          N BYTEs new attributes
  2989.           attributes
  2990.                1 = top left corner
  2991.                2 = top right corner
  2992.                3 = bottom left corner
  2993.                4 = bottom right corner
  2994.                5 = top edge
  2995.                6 = bottom edge
  2996.                7 = left edge
  2997.                8 = right edge
  2998.     EEh  set characters for window frame
  2999.          BYTE video modes command applies to (see opcode ECh)
  3000.          BYTE which characters to set
  3001.         bit 7  if set, copy single following byte to indicated chars
  3002.         bits 4-6  # of first char to change - 1
  3003.         bits 0-3  # of consecutive chars to change
  3004.          N BYTEs new chars (same relative position as attributes above)
  3005.     EFh  set window name
  3006.          BYTE length of name
  3007.          N BYTEs name
  3008.     F0h  clear input field to blanks
  3009.          BYTE field number
  3010.     F1h  fill input field with character
  3011.          BYTE field number
  3012.          BYTE char
  3013.     F2h  set color of input field
  3014.          BYTE field number (1-N)
  3015.          BYTE attribute
  3016.     F3h  set initial contents of input field
  3017.          BYTE field number (1-N)
  3018.          N BYTEs enough chars to exactly fill field as defined by op FFh
  3019.     F4h  position cursor to specific input field
  3020.          BYTE field number (1-N)
  3021.     F5h  change field table entry
  3022.          BYTE field number
  3023.          7-8 BYTEs field table entry (see opcode FFh below)
  3024.     F6h  set field type
  3025.          BYTE field number
  3026.          BYTE type
  3027.     F7h  "multiple fill"  write data to fields with program output bit set
  3028.         in field table entry, in field number order
  3029.          N BYTEs (total length of all program output fields)
  3030.     F8h  scroll field up a line
  3031.          BYTE field number
  3032.     F9h  scroll field down a line
  3033.          BYTE field number
  3034.     FAh  scroll field left
  3035.          BYTE field number
  3036.     FBh  scroll field right
  3037.          BYTE field number
  3038.     FCh  set field table header
  3039.          BYTE number of fields
  3040.          BYTE screen behavior bits
  3041.         bit 7  reserved
  3042.         bit 6  set if menu items may be selected via keyboard
  3043.         bit 5  set if left mouse button may terminate entry
  3044.         bit 4  set if right mouse button may terminate entry
  3045.         bit 3  if set, menu fields return ' ' rather than 'Y' or 'N'
  3046.         bit 2  if set, modified bits reset on return to application
  3047.         bits 0,1 = 00 no data returned on read of keyboard
  3048.                01 data returned as array of chars containing
  3049.                   all fields packed together, with menu fields
  3050.                   represented by the character 'Y' if selected
  3051.                   and 'N' if not selected
  3052.                10 data returned as variable-length records for
  3053.                   all fields
  3054.                11 data returned as variable-length records for
  3055.                   the fields which were modified
  3056.          BYTE field in which cursor was when entry was terminated
  3057.           (updated by DESQview)
  3058.          BYTE field in which mouse was when entry was terminated
  3059.           (updated by DESQview)
  3060.          BYTE color of field currently pointed to during entry
  3061.          BYTE color of input fields which have been selected
  3062.     FDh  reset modified bit for all fields
  3063.     FEh  reset selected and modified bits for all fields
  3064.     FFh  set up input fields
  3065.          6 BYTEs table header (see opcode FCh above)
  3066.          the field table entries, one for each field
  3067.          BYTE start row    \
  3068.          BYTE start column  \ if menu selection and start is to
  3069.          BYTE end row        / right or below end, select from kbd only
  3070.          BYTE end column   /
  3071.          BYTE field type
  3072.             bits 7,6 = 00 non-entry field
  3073.                    01 echos keystrokes input to make menu selection
  3074.                    10 fill-in field
  3075.                    11 menu selection
  3076.             bit 5  program output--field can be filled by F7h opcode
  3077.             bit 4  reserved
  3078.             bit 3  reserved
  3079.             bit 2  reserved
  3080.             bit 1  set if field selected
  3081.             bit 0  set if field modified
  3082.          BYTE modifier
  3083.               if type is fill-in, then bit flags to determine behavior
  3084.               bit 7  if set, beep when field is full
  3085.               bit 6  move to next field when current field is full
  3086.               bit 5  if set, enter text from right end (for numbers)
  3087.               bit 4  if set, force input to uppercase
  3088.               bit 3  if set, clear old contents on first keystroke
  3089.               bit 2  if set, input returned when cursor moves out
  3090.                  of modified field (API level 2.02+)
  3091.               bit 1  reserved
  3092.               bit 0  reserved
  3093.               if type is menu selection, first key to press to activate
  3094.               00h if have to point-&-click or is an extended-ASCII
  3095.                   keystroke (only if two-key menus enabled)
  3096.          BYTE for menu item, color of field after cursor or mouse
  3097.               passes through it
  3098.          BYTE second key for activating menu selection if field type is
  3099.               C0h (0 = only single key).  This byte is present iff
  3100.               two-letter menu entries selected with opcode E5h, and
  3101.               in that case is present regardless of field type
  3102.          Note: DESQview uses and updates the actual copy of the information
  3103.            which is contained in the stream.  Thus this info must remain
  3104.            intact until after the data entry is complete.
  3105.  
  3106. MODE 01h "QUERY STREAM" (valid only for those opcodes listed here)
  3107.     A0h return logical cursor row in next byte
  3108.     A1h return logical cursor column in next byte
  3109.     A2h return top row of scrolling region in next byte
  3110.     A3h return left column of scrolling region in next byte
  3111.     A4h return row of physical window origin in next byte
  3112.     A5h return column of physical window origin in next byte
  3113.     A6h return height of physcial window in next byte
  3114.     A7h return width of physical window in next byte
  3115.     A8h return row of viewport origin in next byte
  3116.     A9h return column of viewport origin in next byte
  3117.     AAh return height of virtual screen in next byte
  3118.     ABh return width of virtual screen in next byte
  3119.     AFh return current video mode in next byte
  3120.     C0h return current logical cursor position in next two bytes
  3121.     C1h return top left corner of scrolling region in next two bytes
  3122.     C2h return current window position in next two bytes
  3123.     C3h return current window size in next two bytes
  3124.     C4h return current viewport origin in next two bytes
  3125.     C5h return current virtual screen size in next two bytes
  3126.     D0h \ overwritten with D0h if frames may fall off screen edge
  3127.     D1h /               D1h if frames always displayed entirely
  3128.     D2h \ overwritten with D2h if DESQview controls color palette
  3129.     D3h /               D3h if application changes color palette
  3130.     D4h \ overwritten with D4h if window visible
  3131.     D5h /               D5h if window hidden
  3132.     D6h \ overwritten with D6h if window has frame
  3133.     D7h /               D7h if window unframed
  3134.     D8h \ overwritten with D8h if reading characters from window
  3135.     D9h /               D9h if reading attributes from window
  3136.     DAh \ overwritten with DAh if using logical attributes
  3137.     DBh /               DBh if using physical attributes
  3138.     DCh \ overwritten with DCh if TTY control char interpretation on
  3139.     DDh /               DDh if TTY control char interpretation off
  3140.     DEh \ overwritten with DEh if writing both characters and attributes
  3141.     DFh /               DFh if leaving attributes untouched
  3142.     E2h return current color in next byte
  3143.     ECh get logical attributes for window contents
  3144.         BYTE execute call if currently in specified video mode
  3145.         bit 7    monochrome
  3146.         bit 6    color text, EGA/VGA graphics
  3147.         bit 5    medium-resolution CGA graphics
  3148.         bit 4    high-resolution CGA graphics
  3149.         BYTE which attributes to get
  3150.         bit 7 unused???
  3151.         bits 4-6 first attribute to get - 1
  3152.         bits 0-3 # consecutive attributes
  3153.         N BYTEs buffer to hold attributes
  3154.     EDh get logical attributes for window frame
  3155.         BYTE execute call if currently in video mode (see opcode ECh)
  3156.         BYTE which attributes to get
  3157.         bit 7 unused???
  3158.         bits 4-6 first attribute to get - 1
  3159.         bits 0-3 # consecutive attributes
  3160.         N BYTEs buffer to hold attributes
  3161.     EEh get characters for window frame
  3162.         BYTE execute call if currently in video mode (see opcode ECh)
  3163.         BYTE which attributes to get
  3164.         bit 7 unused???
  3165.         bits 4-6 first char to get - 1
  3166.         bits 0-3 # consecutive chars
  3167.         N BYTEs buffer to hold chars
  3168.     EFh return current window name
  3169.         BYTE    max length of returned name
  3170.         N BYTEs buffer to hold window name
  3171.     F3h return contents of input field
  3172.         BYTE field number
  3173.         N BYTEs buffer to hold field contents (size exactly equal to field
  3174.             size)
  3175.     F5h get field table entry
  3176.         BYTE field number
  3177.         7-8 BYTEs buffer to hold field table entry
  3178.     F6h get type of a field
  3179.         BYTE field number
  3180.         BYTE type
  3181.     FCh get field table header
  3182.         6 BYTEs buffer to store header
  3183.  
  3184. MODE 10h "MANAGER STREAM" (valid only for opcodes listed here)
  3185.     00h allow window to be moved horizontally
  3186.     01h allow window to be moved vertically
  3187.     02h allow window to change width
  3188.     03h allow window to change height
  3189.     04h allow window to be scrolled horizontally
  3190.     05h allow window to be scrolled vertically
  3191.     06h allow "Close Window" menu selection
  3192.     07h allow window to be hidden
  3193.     08h allow "Mark" menu
  3194.     0Eh allow "Scissors" menu
  3195.     10h allow DESQview main menu to be popped up
  3196.     11h allow "Switch Windows" menu
  3197.     12h allow "Open Window" menu
  3198.     13h allow "Quit" menu selection
  3199.     20h-33h opposite of 00h-13h, disallow specified action
  3200.     40h notify if horizontal position of window changes
  3201.     41h notify if vertical position of window changes
  3202.     42h notify if width of window changes
  3203.     43h notify if height of window changes
  3204.     44h notify if window scrolled horizontally
  3205.     45h notify if window scrolled vertically
  3206.     46h notify if window is closed--program has to clean up and exit itself
  3207.     47h notify if window is hidden
  3208.     48h notify if "?" on main menu selected
  3209.     49h notify if pointer message sent to window
  3210.     4Ah notify if window is made active
  3211.     4Bh notify if window is switched away from
  3212.     4Ch notify if video mode changes
  3213.     4Dh notify if "Scissors" menu "Cut" option selected
  3214.     4Eh notify if "Scissors" menu "Copy" option selected
  3215.     4Fh notify if "Scissors" menu "Paste" option selected
  3216.     50h notify if DESQview main menu popped up
  3217.     51h notify if DESQview main menu popped down
  3218.     60h-71h  opposite of 40h-51h: don't notify on specified event
  3219.     84h attach window to parent task's window (both move together)
  3220.     85h detach window from parent task's window (may move independently)
  3221.     86h disable background operation
  3222.     87h enable running in background
  3223.     88h set minimum size of physical window
  3224.         BYTE rows
  3225.         BYTE columns
  3226.     89h set maximum size of physical window
  3227.         BYTE rows
  3228.         BYTE cols
  3229.     8Ah set primary asynchronous notification routine
  3230.         DWORD address of routine, 0000h:0000h means none
  3231.           on entry ES:DI = handle of window, DS:SI is 32-bit value set
  3232.           by 8Bh opcode
  3233.                mailbox contains message indicating event
  3234.                   Opcode
  3235.                    40h  horizontal movement
  3236.                    DWORD object handle of window
  3237.                    BYTE  new row
  3238.                    BYTE  new col
  3239.                    41h  vertical movement
  3240.                    DWORD object handle of window
  3241.                    BYTE  new row
  3242.                    BYTE  new col
  3243.                    42h  horizontal size change
  3244.                    DWORD object handle of window
  3245.                    BYTE  new rows
  3246.                    BYTE  new cols
  3247.                    43h  vertical size change
  3248.                    DWORD object handle of window
  3249.                    BYTE  new rows
  3250.                    BYTE  new cols
  3251.                    44h  scrolled horizontally
  3252.                    DWORD object handle of window
  3253.                    BYTE  mouse row within window
  3254.                    BYTE  mouse column within window
  3255.                    BYTE  field mouse is on, 0 if none
  3256.                    BYTE  amount moved: >0 right, <0 left, 0 done
  3257.                    45h  scrolled vertically
  3258.                    DWORD object hande of window
  3259.                    BYTE  mouse row within window
  3260.                    BYTE  mouse column within window
  3261.                    BYTE  field mouse is on, 0 if none
  3262.                    BYTE  amount moved: >0 down, <0 up, 0 done
  3263.                    46h  window closed
  3264.                    DWORD object handle of window
  3265.                    BYTE  mouse pointer row
  3266.                    BYTE  mouse pointer column
  3267.                    BYTE  field mouse is on, 0 if none
  3268.                    47h  window hidden
  3269.                    48h  Help for Program selected
  3270.                    DWORD object handle of window
  3271.                    BYTE  mouse pointer row
  3272.                    BYTE  mouse pointer column
  3273.                    BYTE  field mouse is on, 0 if none
  3274.                    49h  pointer message sent to window
  3275.                    4Ah  switched to window from another ("raise")
  3276.                    4Bh  switched away from the window ("lower")
  3277.                    4Ch  video mode changed
  3278.                    BYTE new video mode
  3279.                    4Dh  Scissors/cUt selected
  3280.                    DWORD object handle of window
  3281.                    BYTE  row of upper left corner
  3282.                    BYTE  column of upper left corner
  3283.                    BYTE  field number ul corner is in, 0=none
  3284.                    DWORD handle of orphaned window created to
  3285.                      hold data
  3286.                    BYTE  height of region
  3287.                    BYTE  width of region
  3288.                    4Eh  Scissors/Copy selected
  3289.                    DWORD object handle of window
  3290.                    BYTE  row of upper left corner
  3291.                    BYTE  column of upper left corner
  3292.                    BYTE  field number ul corner is in, 0=none
  3293.                    DWORD handle of orphaned window created to
  3294.                      hold data
  3295.                    BYTE  height of region
  3296.                    BYTE  width of region
  3297.                    4Fh  Scissors/Paste selected
  3298.                    DWORD object handle of window
  3299.                    BYTE  row of upper left corner
  3300.                    BYTE  column of upper left corner
  3301.                    BYTE  field number ul corner is in, 0=none
  3302.                    DWORD handle of orphaned window with data
  3303.                    BYTE  height of region
  3304.                    BYTE  width of region
  3305.                    50h  main menu popped up
  3306.                    51h  main menu popped down
  3307.           routine should restore all registers before returning
  3308.     8Bh set async notification parameter
  3309.         DWORD 32-bit value passed to async routine in DS:SI
  3310.     ACh (DV2.2) perform regular select field attribute processing
  3311.     ADh (DV2.2) protect attributes in selected field from being lost
  3312.     AEh make window default notify window for owning app (API level 2.00+)
  3313.     AFh set selected field marker character
  3314.         BYTE character to display at left edge of selected fields
  3315.     BCh set standard field processing mode 
  3316.     BDh set alternate field processing mode (enables cursor pad for menus)
  3317.     BEh enables changing reverse logical attributes with ECh opcode
  3318.     BFh disables changing reverse logical attributes with ECh opcode
  3319.     C0h make current window topmost in system
  3320.     C1h force current process into foreground
  3321.     C2h make current window topmost in process
  3322.     C3h position mouse pointer relative to origin of current field
  3323.         BYTE rows below upper left corner of field
  3324.         BYTE columns to right of upper left corner of field
  3325.     C4h position mouse pointer relative to origin of given field
  3326.         BYTE field number
  3327.         BYTE rows below upper left corner of field
  3328.         BYTE columns to right of upper left corner of field
  3329.     C5h hide current window
  3330.     C6h show windows for this process
  3331.     C7h hide all windows for this process
  3332.     C8h suspend process and hide all its windows
  3333.     C9h force current process into background
  3334.     CAh make current window bottom-most in process
  3335.     CBh cancel current window manager operation, remove DV menu, give 
  3336.         control to topmost application
  3337.     CCh close window
  3338.     CEh reorder windows
  3339.         DWORD pointer to null-terminated list of words
  3340.           each word is segment of object handle for a window
  3341.  
  3342. MODES 14h to 1Fh "USER STREAMS"
  3343.     normally NOPs, but may be defined by SETESC message to invoke FAR
  3344.     routines, one for each mode number
  3345.       on entry to handler,
  3346.         DS:SI = first byte of actual stream (not header)
  3347.         CX = #bytes in stream
  3348.         ES:DI = window's handle
  3349. ---------------------------------------------
  3350. INT 15 - DESQview 2.2 - SEND MESSAGE - SET PRIORITY
  3351.     AH = 12h
  3352.     BH = 06h
  3353.     BL = object
  3354.         00h object handle in DWORD on top of stack
  3355.     STACK: DWORD new priority of object in task's OBJECTQ 
  3356. ---------------------------------------------
  3357. INT 15 - DESQview 2.2 - SEND MESSAGE - GET PRIORITY
  3358.     AH = 12h
  3359.     BH = 07h
  3360.     BL = object
  3361.         00h object handle in DWORD on top of stack
  3362. Return: STACK: DWORD object priority
  3363. Note:    initially all objects have the same default value.  Should make 
  3364.     relative adjustments to this default value.
  3365. ---------------------------------------------
  3366. INT 15 - TopView - SEND MESSAGE - "SIZEOF" - GET OBJECT SIZE
  3367.     AH = 12h
  3368.     BH = 08h
  3369.     BL = object
  3370.         00h handle in DWORD on top of stack
  3371.         timer: elapsed time since timer started
  3372.         pointer: number of messages queued to pointer object
  3373.         panel: number of panels in panel file
  3374.         01h total chars in current task's default window
  3375.         02h number of messages in task's mailbox (task's handle on stack)
  3376.         03h number of messages in current task's mailbox
  3377.         04h number of input buffers queued in task's kbd (handle on stack)
  3378.         05h number of input buffers queued for current task's default kbd
  3379.         06h number of objects queued in OBJECTQ (task's handle on stack)
  3380.         07h number of objects queued in current task's OBJECTQ
  3381. Return: DWORD on stack is result
  3382. ---------------------------------------------
  3383. INT 15 - TopView - SEND MESSAGE - "LEN" - GET OBJECT LENGTH
  3384.     AH = 12h
  3385.     BH = 09h
  3386.     BL = object
  3387.         00h handle in DWORD on top of stack
  3388.         window: chars/line
  3389.         timer: timer remaining before timer expires
  3390.         01h number of chars/line in current task's default window
  3391. Return: DWORD on top of stack is length
  3392. ---------------------------------------------
  3393. INT 15 - TopView - SEND MESSAGE - "ADDTO" - SET OBJECT BITS
  3394.     AH = 12h
  3395.     BH = 0Ah
  3396.     BL = object
  3397.         00h handle is DWORD on top of stack
  3398.         window: write characters and attributes
  3399.         timer: start timer for specified interval
  3400.         pointer: set control flags
  3401.         01h write characters and attributes to task's default window
  3402.         02h send message/status by value to mailbox (task's handle on stack)
  3403.         03h send message/status by value to current task's default mailbox
  3404.         04h set control flags on KEYBOARD object (handle on top of stack)
  3405.         05h set control flags on task's default KEYBOARD object
  3406.     STACK: (if mailbox) DWORD status
  3407.                 DWORD length of message
  3408.                 DWORD address
  3409.            (if timer)   DWORD duration in 1/100 seconds
  3410.            (if window)  DWORD count of characters
  3411.                 DWORD address of characters
  3412.                 DWORD count of attributes
  3413.                 DWORD address of attributes
  3414.            (otherwise)  DWORD bits to set
  3415. For keyboard objects, the bits have the following significance:
  3416.     bit 15 reserved, can't be set
  3417.     bit 14 unused
  3418.     bit 13 reserved, can't be set
  3419.     bit 12-5 unused
  3420.     bit 4  filter all keys (used with handler established by SETESC)
  3421.     bit 3  program continues executing while input in progress
  3422.     bit 2  insert mode active
  3423.     bit 1  keyboard is active
  3424.     bit 0  keyboard is in field mode
  3425. For pointer objects, the bits have the following significance:
  3426.     bit 15 reserved, can't be set
  3427.     bit 14-8 unused
  3428.     bit 7  mouse pointer is hidden while in window
  3429.     bit 6  get messages even if window not topmost
  3430.     bit 5  get messages even if window not foreground
  3431.     bit 4  mouse button must be held 1/2 second before it "clicks"
  3432.     bit 3  pointer position is relative to screen origin, not window origin
  3433.     bit 2  send message on button release as well as button press
  3434.     bit 1  unused???
  3435.     bit 0  send message only on button activity, not movement
  3436.            DV-specific, and INT 15h/AX=DE0Fh must have been called first
  3437. ---------------------------------------------
  3438. INT 15 - TopView - SEND MESSAGE - "SUBFROM" - RESET OBJECT BITS
  3439.     AH = 12h
  3440.     BH = 0Bh
  3441.     BL = object
  3442.         00h handle is DWORD on top of stack
  3443.         window:  write attributes only
  3444.         mailbox: send message by reference
  3445.         pointer: reset control flags
  3446.         01h write attributes only to task's default window
  3447.         02h send msg/status by reference to mailbox (task's handle on stack)
  3448.         03h send msg/status by reference to current task's mailbox
  3449.         04h clear control flags on KEYBOARD object (handle on top of stack)
  3450.         05h clear control flags on task's default KEYBOARD object
  3451.         06h remove specific object from OBJECTQ (task's handle on stack)
  3452.         07h remove specific object from task's default OBJECTQ
  3453.     STACK: (if mailbox) DWORD status
  3454.                 DWORD length
  3455.                 DWORD address
  3456.            (if window)  DWORD number of attributes to write
  3457.                 DWORD address of attributes
  3458.            (if objectq) DWORD handle of object to remove
  3459.            (otherwise)  DWORD indicates which bits to clear
  3460. ---------------------------------------------
  3461. INT 15 - TopView - SEND MESSAGE - "OPEN" - OPEN OBJECT
  3462.     AH = 12h
  3463.     BH = 0Ch
  3464.     BL = object
  3465.         00h handle is DWORD on top of stack
  3466.         window:   fill with given character
  3467.         keyboard: attach to a window
  3468.         timer:      open
  3469.         pointer:  start taking input for window
  3470.         panel:      associate with a panel file
  3471.         01h fill task's default window with given character
  3472.         02h open given task's mailbox for input (task's handle on stack)
  3473.         03h open current task's mailbox
  3474.         04h attach a KEYBOARD to a window (handle on top of stack)
  3475.         05h attach task's default KEYBOARD to a window
  3476.         06h open a task's OBJECTQ (task's handle on top of stack)
  3477.         07h open current task's OBJECTQ
  3478.      STACK: (if window)   DWORD character to fill with
  3479.         (if keyboard) DWORD handle of window to attach to
  3480.         (if pointer)  DWORD handle of window to attach to
  3481.         (if panel)    DWORD length of filename
  3482.                   DWORD address of filename
  3483.         (otherwise)   nothing
  3484. Notes: special action taken if first byte of panel file name is 1Bh
  3485.        if first two bytes of panel file "name" are C0hC3h, then the "name" IS
  3486.        the panel file
  3487.        result code of open may be retrieved with STATUS message
  3488. ---------------------------------------------
  3489. INT 15 - TopView - SEND MESSAGE - "CLOSE" - CLOSE OBJECT
  3490.     AH = 12h
  3491.     BH = 0Dh
  3492.     BL = object
  3493.         00h handle is DWORD on top of stack
  3494.         timer:      close
  3495.         keyboard: detach from window
  3496.         pointer:  stop taking input
  3497.         panel:      close
  3498.         02h close given task's mailbox (task's handle on top of stack)
  3499.         03h close task's default mailbox
  3500.         04h close KEYBOARD object (handle on top of stack)
  3501.         05h close task's default KEYBOARD
  3502.         06h close givent task's OBJECTQ (task's handle on top of stack)
  3503.         07h close current task's OBJECTQ
  3504. ---------------------------------------------
  3505. INT 15 - TopView - SEND MESSAGE - "ERASE" - ERASE OBJECT
  3506.     AH = 12h
  3507.     BH = 0Eh
  3508.     BL = object
  3509.         00h handle is DWORD on top of stack
  3510.         window:   clear
  3511.         keyboard: discard input
  3512.         timer:      cancel current interval
  3513.         pointer:  discard all pending messages
  3514.         01h clear task's default window
  3515.         02h discard all queued messages in mailbox (handle on top of stack)
  3516.         03h discard all queued messages in current task's default mailbox
  3517.         04h discard all input queued to KEYBOARD (handle on top of stack)
  3518.         05h discard all input queued to task's default KEYBOARD
  3519.         06h remove all objects from OBJECTQ (task's handle on top of stack)
  3520.         07h remove all objects from current task's OBJECTQ
  3521. ---------------------------------------------
  3522. INT 15 - TopView - SEND MESSAGE - "STATUS" - GET OBJECT STATUS
  3523.     AH = 12h
  3524.     BH = 0Fh
  3525.     BL = object
  3526.         00h handle is DWORD on top of stack
  3527.         timer:     is it running?
  3528.         pointer: return status of last message
  3529.         panel:     verify success of last OPEN or APPLY
  3530.         02h return status of last msg READ from mailbox (handle on stack)
  3531.         03h return status of last msg READ from task's default mailbox
  3532.         04h get status of last msg from task's KEYBOARD (task handle on stk)
  3533.         05h get status of last msg from task's default KEYBOARD
  3534.         06h return whether OBJECTQ is open or not (handle on top of stack)
  3535.         07h return whether task's default OBJECTQ is open or not
  3536. Return: DWORD on top of stack is status
  3537. Note: if object is a panel object, the status indicates the error code:
  3538.     14h panel name not in panel directory
  3539.     15h not enough memory to apply panel
  3540.     16h invalid panel format
  3541.     17h panel file already open
  3542.     81h-92h  DOS error codes+80h
  3543.     95h not enough memory to open panel file
  3544.     98h null panel file name
  3545. ---------------------------------------------
  3546. INT 15 - TopView - SEND MESSAGE - "EOF" - GET OBJECT EOF STATUS
  3547.     AH = 12h
  3548.     BH = 10h
  3549.     BL = object
  3550.         00h handle is DWORD on top of stack
  3551.         01h returns TRUE if logical cursor past end of task's def window
  3552.         02h return ??? for task's mailbox (task's handle on top of stack)
  3553.         03h return ??? for current task's mailbox
  3554. Return: DWORD on top of stack is status
  3555. ---------------------------------------------
  3556. INT 15 - TopView - SEND MESSAGE - "AT" - POSITION OBJECT CURSOR
  3557.     AH = 12h
  3558.     BH = 11h
  3559.     BL = object
  3560.         00h window's handle is DWORD on top of stack
  3561.         01h position logical cursor on task's default window
  3562.     STACK: DWORD column
  3563.            DWORD row
  3564. ---------------------------------------------
  3565. INT 15 - TopView - SEND MESSAGE - "SETNAME" - ASSIGN NAME TO MAILBOX
  3566.     AH = 12h
  3567.     BH = 11h
  3568.     BL = mailbox to name
  3569.         00h DWORD on top of stack is mailbox handle
  3570.         02h use given task's mailbox (task's handle on top of stack)
  3571.         03h use current task's default mailbox
  3572.     STACK: DWORD length of name
  3573.            DWORD address of name
  3574. ---------------------------------------------
  3575. INT 15 - TopView - SEND MESSAGE - "SETSCALE" - SET POINTER SCALE FACTOR
  3576.     AH = 12h
  3577.     BX = 1100h
  3578.     STACK: DWORD object handle for pointer object
  3579.            DWORD number of colums to scale pointer position to
  3580.            DWORD number of rows to scale pointer position to
  3581. ---------------------------------------------
  3582. INT 15 - TopView - SEND MESSAGE - "READN" - GET NEXT N OBJECT BYTES
  3583.     AH = 12h
  3584.     BH = 12h
  3585.     BL = object
  3586.         00h handle is DWORD on top of stack
  3587.         01h read next N chars/attributes on task's default window
  3588.     STACK: DWORD count
  3589. Return: STACK: DWORD width of screen line
  3590.            DWORD address
  3591.            DWORD count actually read
  3592. ---------------------------------------------
  3593. INT 15 - TopView - SEND MESSAGE - "GETSCALE" - GET POINTER SCALE FACTOR
  3594.     AH = 12h
  3595.     BX = 1200h
  3596.     STACK: DWORD object handle for pointer
  3597. Return: STACK: DWORD pointer pos scaled as if window were this many colums wide
  3598.            DWORD pointer pos scaled as if window were this many rows high
  3599. ---------------------------------------------
  3600. INT 15 - TopView - SEND MESSAGE - "REDRAW" - REDRAW WINDOW
  3601.     AH = 12h
  3602.     BH = 13h
  3603.     BL = window object
  3604.         00h DWORD on top of stack is handle for window to redraw
  3605.         01h redraw task's default window
  3606. ---------------------------------------------
  3607. INT 15 - TopView - SEND MESSAGE - "SETICON" - SPECIFY POINTER ICON
  3608.     AH = 12h
  3609.     BX = 1300h
  3610.     STACK: DWORD object handle for pointer
  3611.            DWORD character to use for pointer
  3612. ---------------------------------------------
  3613. INT 15 - TopView - SEND MESSAGE - "SETESC" - SET ESCAPE ROUTINE ADDRESS
  3614.     AH = 12h
  3615.     BH = 14h
  3616.     BL = message modifier
  3617.         00h handle is DWORD on top of stack
  3618.         01h define user stream
  3619.         04h intercept keystrokes from KEYBOARD to a window (handle on stack)
  3620.         05h intercept keystrokes from task's default KEYBOARD to a window
  3621.     STACK: (if window)   DWORD user stream number (14h-1Fh)
  3622.                  DWORD address of FAR user stream handler
  3623.            (if keyboard) DWORD address of FAR filter function
  3624.  
  3625. The keyboard filter function is called when the keyboard is in field mode.  On
  3626. entry,
  3627.     AL = character
  3628.     AH = 00h or extended ASCII code if AL = 00h
  3629.     BL = field number
  3630.     CH = cursor column
  3631.     CL = cursor row
  3632.     DL = field type modifier (sixth item in field table entry)
  3633.     DH = ??? (seventh item in field table entry)
  3634.     ES:SI = window's handle
  3635. (also, in DV 2.00, DS:DI points to the field table entry.  This may change in
  3636.  other versions)
  3637. The filter function should return
  3638.     AH = 00h use keystroke
  3639.          01h ignore keystroke
  3640.          >1 beep and ignore keystroke
  3641. ---------------------------------------------
  3642. INT 15 - TopView - SEND MESSAGE - "LOCK" - REQUEST EXCLUSIVE ACCESS TO RESOURCE
  3643.     AH = 12h
  3644.     BH = 14h
  3645.     BL = object
  3646.         00h mailbox handle is DWORD on top of stack
  3647.         02h use given task's mailbox (task's handle on top of stack)
  3648.         03h use current task's default mailbox
  3649. Note: release exclusive access by sending CLOSE message to mailbox
  3650.       access may be requested multiple times, and requires multiple CLOSEs
  3651. ---------------------------------------------
  3652. INT 15 - DESQview 2.2 - SEND MESSAGE - SET FLAGS
  3653.     AH = 12h
  3654.     BH = 15h
  3655.     BL = object
  3656.         00h DWORD on top of stack
  3657.         mailbox, keyboard, or pointer only
  3658.         02h mailbox for task whose handle is on top of stack
  3659.         03h mailbox for current task
  3660.         04h keyboard for task whose handle is on top of stack
  3661.         05h keyboard for current task
  3662.     STACK: DWORD flags
  3663.         if mailbox:
  3664.             bit 0: all mail messages in common memory
  3665.             bit 1: allow write even if closed
  3666.             bit 2: don't erase messages when mailbox closed
  3667.         if keyboard:
  3668.             bit 5: exclusive input when keyboard in use for input
  3669. Return: nothing
  3670. Note: this call is only available if the API level has been set to at least 2.2
  3671. ---------------------------------------------
  3672. INT 15 - DESQview 2.2 - SEND MESSAGE - GET FLAGS
  3673.     AH = 12h 
  3674.     BH = 16h
  3675.     BL = object
  3676.         00h DWORD on top of stack
  3677.         mailbox, keyboard, or pointer only
  3678.         02h mailbox for task whose handle is on top of stack
  3679.         03h mailbox for current task
  3680.         04h keyboard for task whose handle is on top of stack
  3681.         05h keyboard for current task
  3682. Return: STACK: DWORD current control flags
  3683. Note: this call is only available if the API level has been set to at least 2.2
  3684. ---------------------------------------------
  3685. INT 15 - VMiX - WAKE PROCESS
  3686.     AH = 13h
  3687.     STACK:    WORD    process ID
  3688. Return: AX = status
  3689. ---------------------------------------------
  3690. INT 15 - VMiX - CLEAR WINDOW
  3691.     AH = 14h
  3692.     STACK:    WORD    top left corner of window
  3693.         WORD    bottom right corner of window
  3694. Return: AX = status
  3695. ---------------------------------------------
  3696. INT 15 - VMiX - SET BANNER WINDOW MESSAGE
  3697.     AH = 15h
  3698.     STACK:    DWORD    pointer to ASCIZ banner    message
  3699. Return: AX = status
  3700. ---------------------------------------------
  3701. INT 15 - VMiX - SET ROOT WINDOW SIZE AND HOME CURSOR
  3702.     AH = 16h
  3703.     STACK:    DWORD    pointer to I/O Request Packet
  3704.         WORD    top left corner of window
  3705.         WORD    bottom right corner of window
  3706. Return: AX = status
  3707. ---------------------------------------------
  3708. INT 15 - VMiX - GET CONSOLE WINDOW COLORS
  3709.     AH = 17h
  3710. Return: AH = foreground color
  3711.     AL = background color
  3712. ---------------------------------------------
  3713. INT 15 - VMiX - SET CONSOLE COLORS
  3714.     AH = 18h
  3715.     STACK:    WORD    new background/foreground colors
  3716. Return: AX = color
  3717. ---------------------------------------------
  3718. INT 15 - VMiX v2+ - ???
  3719.     AH = 19h
  3720.     STACK: WORD ???
  3721. Return: ???
  3722. ---------------------------------------------
  3723. INT 15 - VMiX v2+ - ???
  3724.     AH = 1Ah
  3725.     STACK: 3 WORDs ???
  3726. Return: ???
  3727. ---------------------------------------------
  3728. INT 15 - VMiX v2+ - ???
  3729.     AH = 1Bh
  3730.     STACK: 5 WORDs ???
  3731. Return: ???
  3732. ---------------------------------------------
  3733. INT 15 - VMiX v2+ - ???
  3734.     AH = 1Ch
  3735.     STACK: 5 WORDs ???
  3736. Return: ???
  3737. ---------------------------------------------
  3738. INT 15 - VMiX v2+ - ???
  3739.     AH = 1Dh
  3740.     ???
  3741. Return: ???
  3742. ---------------------------------------------
  3743. INT 15 - VMiX v2+ - ???
  3744.     AH = 1Eh
  3745.     STACK: WORD ???
  3746. Return: ???
  3747. ---------------------------------------------
  3748. INT 15 - DOS 3.10 PRINT.COM - DISABLE CRITICAL REGION FLAG (AT,XT286,PS50+)
  3749.     AX = 2000h
  3750. ---------------------------------------------
  3751. INT 15 - DOS 3.10 PRINT.COM - SET CRITICAL REGION FLAG (AT,XT286,PS50+)
  3752.     AX = 2001h
  3753.     ES:BX -> byte which is to be incremented while in a DOS call
  3754. ---------------------------------------------
  3755. INT 15 - OS HOOK - SETUP SYSREQ ROUTINE (AT,XT286,PS50+)
  3756.     AX = 2010h
  3757.     ???
  3758. Return: ???
  3759. ---------------------------------------------
  3760. INT 15 - OS HOOK - COMPLETION OF SYSREQ FUNCTION (AT,XT286,PS50+)
  3761.     AX = 2011h
  3762.     ???
  3763. Return: ???
  3764. ---------------------------------------------
  3765. INT 15 - SYSTEM - POWER-ON SELF-TEST ERROR LOG (PS50+)
  3766.     AH = 21h
  3767.     AL = subfunction
  3768.         00h read POST log
  3769.         01h write POST log
  3770.         BH = device ID
  3771.         BL = error code
  3772. Return: CF set on error
  3773.     AH = status (00h OK, 01h list full, 80h invalid cmd, 86h unsupported)
  3774.     if function 00h:
  3775.        BX = number of error codes stored
  3776.        ES:DI -> error log
  3777. Note: the log is a series of words, the first byte of which identifies the
  3778.       error code and the second the device.
  3779. ---------------------------------------------
  3780. INT 15 - SYSTEM - READ/MODIFY PROFILES (CONVERTIBLE)
  3781.     AH = 40h
  3782.     AL = subfunction
  3783.         00h get system profile in CX and BX
  3784.         01h set system profile from CX and BX
  3785.         02h get internal modem profile in BX
  3786.         03h set internal modem profile from BX
  3787. ---------------------------------------------
  3788. INT 15 - SYSTEM - WAIT ON EXTERNAL EVENT (CONVERTIBLE)
  3789.     AH = 41h
  3790.     AL = condition type
  3791.         bits 0-2: condition to wait for
  3792.              0 any external event
  3793.              1 compare and return if equal
  3794.              2 compare and return if not equal
  3795.              3 test and return if not zero
  3796.              4 test and return if zero
  3797.         bit 3:    reserved
  3798.         bit 4:    1=port address, 0=user byte
  3799.         bits 5-7: reserved
  3800.     BH = condition compare or mask value
  3801.     BL = timeout value times 55 milliseconds
  3802.         00h means no timeout
  3803.     DX = I/O port address if AL bit 4 set
  3804.     ES:DI -> user byte if AL bit 4 clear
  3805. ---------------------------------------------
  3806. INT 15 - SYSTEM - REQUEST POWER OFF (CONVERTIBLE)
  3807.     AH = 42h
  3808.     AL = 00h to use system profile
  3809.          01h to force suspend regardless of system profile
  3810. ---------------------------------------------
  3811. INT 15 - SYSTEM - READ SYSTEM STATUS (CONVERTIBLE)
  3812.     AH = 43h
  3813. Return: AL = status bits
  3814.         bit 0: LCD detached
  3815.         bit 1: reserved
  3816.         bit 2: RS232/parallel adapter powered on
  3817.         bit 3: internal modem powered on
  3818.         bit 4: power activated by alarm
  3819.         bit 5: standby power lost
  3820.         bit 6: external power in use
  3821.         bit 7: power low
  3822. ---------------------------------------------
  3823. INT 15 - SYSTEM - (DE)ACTIVATE INTERNAL MODEM POWER (CONVERTIBLE)
  3824.     AH = 44h
  3825.     AL = 00h to power off
  3826.          01h to power on
  3827. ---------------------------------------------
  3828. INT 15 - OS HOOK - KEYBOARD INTERCEPT (AT model 3x9,XT2,XT286,CONV,PS)
  3829.     AH = 4Fh
  3830.     AL = scan code
  3831.     CF set
  3832. Return: CF set
  3833.        AL = scan code
  3834.     CF clear
  3835.        scan code should be ignored
  3836. Note: Called by INT 9 handler to translate scan codes
  3837. ---------------------------------------------
  3838. INT 15 - OS HOOK - DEVICE OPEN (AT,XT2,XT286,PS)
  3839.     AH = 80h
  3840.     BX = device ID
  3841.     CX = process type
  3842. Return: CF set on error
  3843.     AH = status
  3844. ---------------------------------------------
  3845. INT 15 - OS HOOK - DEVICE CLOSE (AT,XT2,XT286,PS)
  3846.     AH = 81h
  3847.     BX = device ID
  3848.     CX = process type
  3849. Return: CF set on error
  3850.     AH = status
  3851. ---------------------------------------------
  3852. INT 15 - OS HOOK - DEVICE PROGRAM TERMINATE (AT,XT2,XT286,PS)
  3853.     AH = 82h
  3854.     BX = device ID
  3855. Return: CF set on error
  3856.     AH = status
  3857. Note: closes all devices opened with function 80h
  3858. ---------------------------------------------
  3859. INT 15 - SYSTEM - EVENT WAIT (AT,XT286,CONV,PS)
  3860.     AH = 83h
  3861.     AL = subservice
  3862.         00h = set interval
  3863.         01h = cancel
  3864.     ES:BX -> event flag (bit 7 set when interval expires)
  3865.     CX:DX = number of microseconds to wait (only accurate to 977 us)
  3866. Return: CF set if function already busy
  3867. ---------------------------------------------
  3868. INT 15 - SYSTEM - READ JOYSTICK (AT,XT2,XT286,PS)
  3869.     AH = 84h
  3870.     DX = subservice
  3871.         0000h get switch settings
  3872.         Return: AL = switch settings (bits 7-4)
  3873.         0001h read joystick inputs
  3874.         Return: AX = A(x) value
  3875.             BX = A(y) value
  3876.             CX = B(x) value
  3877.             DX = B(y) value
  3878. ---------------------------------------------
  3879. INT 15 - OS HOOK - SYSTEM REQUEST KEY PRESSED (AT,XT2,XT286,CONV,PS)
  3880.     AH = 85h
  3881.     AL = 00h press
  3882.        = 01h release
  3883. Return: CF set on error
  3884.     AH = status
  3885. Note: called by keyboard decode routine
  3886. ---------------------------------------------
  3887. INT 15 - SYSTEM - WAIT (AT,XT2,XT286,CONV,PS)
  3888.     AH = 86h
  3889.     CX,DX = number of microseconds to wait (only accurate to 977 us)
  3890. Return: CF clear: after wait elapses
  3891.     CF set: immediately due to error
  3892. ---------------------------------------------
  3893. INT 15 - EXTENDED MEMORY - BLOCK MOVE (AT,XT286,PS)
  3894.     AH = 87h
  3895.     CX = number of words to move
  3896.     ES:SI -> global descriptor table (see below)
  3897. Return: CF set on error
  3898.     AH = status
  3899.         00h source copied into destination
  3900.         01h parity error
  3901.         02h interrupt error
  3902.         03h address line 20 gating failed
  3903.  
  3904. Format of global descriptor table:
  3905. Offset    Size    Description
  3906.  00h 16 BYTEs    zeros
  3907.  10h    WORD    source segment length in bytes (2*CX-1 or greater)
  3908.  12h  3 BYTEs    24-bit linear source address, low byte first
  3909.  15h    BYTE    source segment access rights (93h)
  3910.  16h    WORD    zero
  3911.  18h    WORD    destination segment length in bytes (2*CX-1 or greater)
  3912.  1Ah  3 BYTEs    24-bit linear destination address, low byte first
  3913.  1Dh    BYTE    destination segment access rights (93h)
  3914.  1Eh 18 BYTEs    zeros
  3915. ---------------------------------------------
  3916. INT 15 - EXTENDED MEMORY - GET MEMORY SIZE (AT,XT286,PS)
  3917.     AH = 88h
  3918. Return: AX = memory size in K
  3919. ---------------------------------------------
  3920. INT 15 - SYSTEM - SWITCH TO VIRTUAL MODE (AT,XT286,PS50+)
  3921.     AH = 89h
  3922.     BL = interrupt number of IRQ0 (IRQ1-7 use next 7 interrupts)
  3923.     BH = interrupt number of IRQ8 (IRQ9-F use next 7 interrupts)
  3924.     DS:SI -> GDT for protected mode
  3925.            offset 0h  null descriptor
  3926.               8h  GDT descriptor
  3927.              10h  IDT descriptor
  3928.              18h  DS
  3929.              20h  ES
  3930.              28h  SS
  3931.              30h  CS
  3932.              38h  uninitialized, used to build descriptor for BIOS CS
  3933.     CX = offset into protected-mode CS to jump to
  3934. Return: CF set on error
  3935.        AH = 0FFh  error enabling address line 20
  3936. ---------------------------------------------
  3937. INT 15 - OS HOOK - DEVICE BUSY LOOP (AT,XT2,XT286,CONV,PS)
  3938.     AH = 90h
  3939.     AL = type code
  3940.         00h disk
  3941.         01h diskette
  3942.         02h keyboard
  3943.         03h PS/2 pointing device
  3944.         80h network
  3945.         FCh disk reset
  3946.         FDh diskette motor start
  3947.         FEh printer
  3948.     ES:BX -> request block for type codes 80h through BFh
  3949. Return: CF set if wait time satisfied
  3950.     CF clear if driver must perform wait
  3951. Note: type codes are allocated as follows:
  3952.     00-7F non-reentrant devices; OS must arbitrate access
  3953.     80-BF reentrant devices; ES:BX points to a unique control block
  3954.     C0-FF wait-only calls, no complementary INT 15/AH=91h call
  3955. ---------------------------------------------
  3956. INT 15 - OS HOOK - SET FLAG AND COMPLETE INTERRUPT (AT,XT2,XT286,CONV,PS)
  3957.     AH = 91h
  3958.     AL = type code (see AH=90h)
  3959.     ES:BX -> request block for type codes 80h through BFh
  3960. Return: AH = 00h
  3961. ---------------------------------------------
  3962. INT 15 - SYSTEM - GET CONFIGURATION (XT after 1/10/86,AT mdl 3x9,CONV,XT286,PS)
  3963.     AH = C0h
  3964. Return: CF set if BIOS doesn't support call
  3965.     CF clear on success
  3966.         ES:BX -> ROM table (see below)
  3967. Note:    the 1/10/86 XT BIOS returns an incorrect value for the feature byte
  3968.  
  3969. Format of ROM configuration table:
  3970. Offset    Size    Description
  3971.  00h    WORD    number of bytes following
  3972.  02h    BYTE    model: PC=FFh, XT=FEh or FBh, PCjr = FDh, PS/2=F8h
  3973.  03h    BYTE    submodel: distingushes between AT and XT/286, etc.
  3974.  04h    BYTE    BIOS revision: 0 for first release, 1 for 2nd, etc.
  3975.  05h    BYTE    features:
  3976.         bit 7 = DMA channel 3 used by hard disk BIOS
  3977.         bit 6 = 2nd 8259 installed
  3978.         bit 5 = Real-Time Clock installed
  3979.         bit 4 = INT 15h/AH=4Fh called upon INT 9h
  3980.         bit 3 = wait for external event supported
  3981.         bit 2 = extended BIOS area allocated at 640K
  3982.         bit 1 = bus is Micro Channel instead of ISA
  3983.         bit 0 reserved
  3984.  06h    WORD    reserved (0)
  3985.  08h    WORD    reserved (0)
  3986. ---------------------------------------------
  3987. INT 15 - SYSTEM - RETURN EXTENDED-BIOS DATA-AREA SEGMENT ADDRESS (PS)
  3988.     AH = C1h
  3989. Return: CF set on error
  3990.     CF clear if successful
  3991.         ES = segment of data area
  3992. ---------------------------------------------
  3993. INT 15 - SYSTEM - POINTING DEVICE BIOS INTERFACE (PS) - ENABLE/DISABLE
  3994.     AX = C200h
  3995.     BH = 00h disable
  3996.          01h enable
  3997. Return: CF set on error
  3998.     AH = status
  3999.         00h successful
  4000.         01h invalid function
  4001.         02h invalid input
  4002.         03h interface error
  4003.         04h need to resend
  4004.         05h no device handler installed
  4005. ---------------------------------------------
  4006. INT 15 - SYSTEM - POINTING DEVICE BIOS INTERFACE (PS) - RESET
  4007.     AX = C201h
  4008. Return: CF set on error
  4009.          AH = status (see AX=C200h)
  4010.     CF clear if successful
  4011.         BH = device ID
  4012. ---------------------------------------------
  4013. INT 15 - SYSTEM - POINTING DEVICE BIOS INTERFACE (PS) - SET SAMPLING RATE
  4014.     AX = C202h
  4015.     BH = sampling rate
  4016.         00h 10/second
  4017.         01h 20/second
  4018.         02h 40/second
  4019.         03h 60/second
  4020.         04h 80/second
  4021.         05h 100/second
  4022.         06h 200/second
  4023. Return: CF set on error
  4024.         AH = status (see AX=C200h)
  4025. ---------------------------------------------
  4026. INT 15 - SYSTEM - POINTING DEVICE BIOS INTERFACE (PS) - SET RESOLUTION
  4027.     AX = C203h
  4028.     BH = resolution
  4029.         00h one count per mm
  4030.         01h two counts per mm
  4031.         02h four counts per mm
  4032.         03h eight counts per mm
  4033. Return: CF set on error
  4034.         AH = status (see AX=C200h)
  4035. ---------------------------------------------
  4036. INT 15 - SYSTEM - POINTING DEVICE BIOS INTERFACE (PS) - GET TYPE
  4037.     AX = C204h
  4038. Return: CF set on error
  4039.         AH = status (see AX=C200h)
  4040.     CF clear if successful
  4041.         BH = device ID
  4042. ---------------------------------------------
  4043. INT 15 - SYSTEM - POINTING DEVICE BIOS INTERFACE (PS) - INITIALIZE
  4044.     AX = C205h
  4045.     BH = data package size (1 - 8 bytes)
  4046. Return: CF set on error
  4047.         AH = status (see AX=C200h)
  4048. ---------------------------------------------
  4049. INT 15 - SYSTEM - POINTING DEVICE BIOS INTERFACE (PS) - GET/SET SCALING FACTOR
  4050.     AX = C206h
  4051.     BH = subfunction
  4052.         00h return device status
  4053.         Return: BL = status
  4054.                bit 0: right button pressed
  4055.                bit 1: reserved
  4056.                bit 2: left button pressed
  4057.                bit 3: reserved
  4058.                bit 4: 0 if 1:1 scaling, 1 if 2:1 scaling
  4059.                bit 5: device enabled
  4060.                bit 6: 0 if stream mode, 1 if remote mode
  4061.                bit 7: reserved
  4062.             CL = resolution (see AX=C203h)
  4063.               DL = sample rate, reports per second
  4064.         01h set scaling at 1:1
  4065.          02h set scaling at 2:1
  4066. Return: CF set on error
  4067.         AH = status (see AX=C200h)
  4068. ---------------------------------------------
  4069. INT 15 - SYSTEM - POINTING DEVICE BIOS INTERFACE (PS) - SET DEVICE HANDLER ADDR
  4070.     AX = C207h
  4071.     ES:BX = user device handler
  4072. Return: CF set on error
  4073.         AH = status (see AX=C200h)
  4074. --------------------------------------------
  4075. INT 15 - SYSTEM - ENABLE/DISABLE WATCHDOG TIMEOUT (PS50+)
  4076.     AH = C3h
  4077.     AL = 00h disable
  4078.          01h enable
  4079.         BX = timer counter
  4080. Return: CF set on error
  4081. Note: the watchdog timer generates an NMI
  4082. ---------------------------------------------
  4083. INT 15 - SYSTEM - PROGRAMMABLE OPTION SELECT (PS50+)
  4084.     AH = C4h
  4085.     AL = 00h return base POS register address
  4086.          01h enable slot
  4087.          BL = slot number
  4088.          02h enable adapter
  4089. Return: CF set on error
  4090.     DX = base POS register address (if function 00h)
  4091. ---------------------------------------------
  4092. INT 15 - DESQview - GET PROGRAM NAME
  4093.     AX = DE00h
  4094. Return: AX = offset into DESQVIEW.DVO of current program's record (see below)
  4095.  
  4096. Format of program entry in DESQVIEW.DVO:
  4097. Offset    Size    Description
  4098.  00h    BYTE    length of name
  4099.  01h  N BYTEs    name
  4100.       2 BYTEs    keys to invoke program (second = 00h if only one key used)
  4101.     WORD    ??? seems always to be 0000h
  4102.     BYTE    end flag: 00h for all but last entry, which is FFh
  4103. ---------------------------------------------
  4104. INT 15 - DESQview - UPDATE "OPEN WINDOW" MENU
  4105.     AX = DE01h
  4106. Return: nothing
  4107. Note: reads DESQVIEW.DVO, disables Open menu if file not in current directory
  4108. ---------------------------------------------
  4109. INT 15 - DESQview 1.x only - SET ??? FLAG FOR CURRENT WINDOW
  4110.     AX = DE02h
  4111. Return: nothing
  4112. Note:    this call is a NOP in DV 2.x
  4113. ---------------------------------------------
  4114. INT 15 - DESQview 1.x only - GET ??? FOR CURRENT WINDOW
  4115.     AX = DE03h
  4116. Return: AX = ??? for current window
  4117.     BX = ??? for current window
  4118. Note:    this call is a NOP in DV 2.x
  4119. ---------------------------------------------
  4120. INT 15 - DESQview - GET AVAILABLE COMMON MEMORY
  4121.     AX = DE04h
  4122. Return: BX = bytes of common memory available
  4123.     CX = largest block available
  4124.     DX = total common memory in bytes
  4125. ---------------------------------------------
  4126. INT 15 - DESQview - GET AVAILABLE CONVENTIONAL MEMORY
  4127.     AX = DE05h
  4128. Return: BX = K of memory available
  4129.     CX = largest block available
  4130.     DX = total conventional memory in K
  4131. ---------------------------------------------
  4132. INT 15 - DESQview - GET AVAILABLE EXPANDED MEMORY
  4133.     AX = DE06h
  4134. Return: BX = K of expanded memory available
  4135.     CX = largest block available
  4136.     DX = total expanded memory in K
  4137. ---------------------------------------------
  4138. INT 15 - DESQview - "APPNUM" - GET CURRENT PROGRAM'S NUMBER
  4139.     AX = DE07h
  4140. Return: AX = number of program as it appears on the "Switch Windows" menu
  4141. ---------------------------------------------
  4142. INT 15 - DESQview - GET ???
  4143.     AX = DE08h
  4144. Return: AX = 0000h if ??? is not set to the current task
  4145.          0001h if ??? is set to the current task
  4146. ---------------------------------------------
  4147. INT 15 - DESQview - UNIMPLEMENTED
  4148.     AX = DE09h
  4149. Return: nothing (NOP in DV 1.x and 2.x)
  4150. ---------------------------------------------
  4151. INT 15 - DESQview 2.x - "DBGPOKE" - DISPLAY CHARACTER ON STATUS LINE
  4152.     AX = DE0Ah
  4153.     BL = character
  4154. Return: character displayed, next call will display in next position (which
  4155.     wraps back to the start of the line if off the right edge of screen)
  4156. Notes:    displays character on bottom line of *physical* screen, regardless
  4157.     of current size of window (even entirely hidden)
  4158.     does not know about graphics display modes, just pokes the characters
  4159.     into display memory
  4160. ---------------------------------------------
  4161. INT 15 - DESQview 2.x - "APILEVEL" - DEFINE MINIMUM API LEVEL REQUIRED
  4162.     AX = DE0Bh
  4163.     BL = API level major version number
  4164.     BH = API level minor version number
  4165. Return: AX = maximum API level (AL = major, AH = minor)
  4166. Note:    if the requested API level is greater than the version of DESQview, a
  4167.     "You need a newer version" error window is popped up
  4168. ---------------------------------------------
  4169. INT 15 - DESQview 2.x - "GETMEM" - ALLOCATE "SYSTEM" MEMORY
  4170.     AX = DE0Ch
  4171.     BX = number of bytes
  4172. Return: ES:DI -> allocated block
  4173. ---------------------------------------------
  4174. INT 15 - DESQview 2.x - "PUTMEM" - DEALLOCATE "SYSTEM" MEMORY
  4175.     AX = DE0Dh
  4176.     ES:DI -> previously allocated block
  4177. Return: nothing
  4178. ---------------------------------------------
  4179. INT 15 - DESQview 2.x - FIND MAILBOX BY NAME
  4180.     AX = DE0Eh
  4181.     ES:DI -> name to find
  4182.     CX = length of name
  4183. Return: BX = 0000h not found
  4184.          0001h found
  4185.         DS:SI = object handle
  4186. ---------------------------------------------
  4187. INT 15 - DESQview 2.x - ENABLE DESQview EXTENSIONS
  4188.     AX = DE0Fh
  4189. Return: AX and BX destroyed (seems to be bug, weren't saved&restored)
  4190. Notes: sends a manager stream with opcodes AEh, BDh, and BFh to task's window
  4191.       enables an additional mouse mode
  4192. ---------------------------------------------
  4193. INT 15 - DESQview 2.x - "PUSHKEY" - PUT KEY INTO KEYBOARD INPUT STREAM
  4194.     AX = DE10h
  4195.     BH = scan code
  4196.     BL = character
  4197. Return: nothing
  4198. Note: a later read will get the keystroke as if it had been typed by the user
  4199.     early copies of DV 2.00 destroy AX, BX, ES, and DI
  4200. ---------------------------------------------
  4201. INT 15 - DESQview 2.x - ENABLE/DISABLE AUTOMATIC JUSTIFICATION OF WINDOW
  4202.     AX = DE11h
  4203.     BL = 00h      viewport will not move automatically
  4204.          nonzero  viewport will move to keep cursor visible
  4205. Return: nothing
  4206. ---------------------------------------------
  4207. INT 15 - DESQview 2.01+ - SET ???
  4208.     AX = DE12h
  4209.     BX = 0000h    clear ??? flag
  4210.          nonzero  set ??? flag
  4211. Return: nothing
  4212. ---------------------------------------------
  4213. INT 15 - DESQview 2.2 - GET CRITICAL NESTING COUNT
  4214.     AX = DE13h
  4215. Return: BX = number of calls to BEGINC (see INT 15/AX=101Bh) without matching
  4216.          ENDC (see INT 15/AX=101Ch)
  4217. ---------------------------------------------
  4218. INT 15 - DESQview 2.2 - GET OBJECT TYPE
  4219.     AX = DE14h
  4220.     ES:DI -> object
  4221. Return: BL = 00h not an object
  4222.          08h window or task
  4223.          09h mailbox
  4224.          0Ah keyboard
  4225.          0Bh timer
  4226.          0Ch objectq
  4227.          0Fh pointer
  4228.          10h panel
  4229. ---------------------------------------------
  4230. INT 15 - DESQview 2.2 - SET MAILBOX ERROR HANDLING
  4231.     AX = DE15h
  4232.     BL = 00h post system error on conditions listed below
  4233.          01h return carry flag set on calls to ADDTO, SUBFROM, and WRITE
  4234.          messages sent to mailboxes which fail due to lack of system
  4235.          or common memory
  4236. Return: nothing
  4237. ---------------------------------------------
  4238. INT 15 - DESQview 2.2 - GET MAILBOX ERROR HANDLING
  4239.     AX = DE16h
  4240. Return: BL = 00h post system error
  4241.          01h return carry flag set
  4242. ---------------------------------------------
  4243. INT 15 - DESQview 2.2 - reserved
  4244.     AX = DE17h
  4245. Return: pops up "Programming error" window
  4246. Note: AX = 1117h is NOT identical to this call
  4247. ---------------------------------------------
  4248. INT 15 - DESQview 2.2 - ???
  4249.     AX = DE18h
  4250. Note: calls video driver (NOP for Hercules driver)
  4251. ---------------------------------------------
  4252. INT 16 - KEYBOARD - READ CHAR FROM BUFFER, WAIT IF EMPTY
  4253.     AH = 00h
  4254. Return: AH = scan code
  4255.     AL = character
  4256. ---------------------------------------------
  4257. INT 16 - KEYBOARD - CHECK BUFFER, DO NOT CLEAR
  4258.     AH = 01h
  4259. Return: ZF clear if character in buffer
  4260.         AH = scan code
  4261.         AL = character
  4262.     ZF set if no character in buffer
  4263. ---------------------------------------------
  4264. INT 16 - KEYBOARD - GET SHIFT STATUS
  4265.     AH = 02h
  4266.     AL = shift status bits
  4267.         0 = right shift key depressed
  4268.         1 = left shift key depressed
  4269.         2 = CTRL depressed
  4270.         3 = ALT depressed
  4271.         4 = SCROLL LOCK active
  4272.         5 = NUM LOCK active
  4273.         6 = CAPS LOCK active
  4274.         7 = INSERT state active
  4275. ---------------------------------------------
  4276. INT 16 - KEYBOARD - SET DELAYS (Jr,AT model 339,XT286,PS)
  4277.     AH = 03h
  4278.     AL = subfunction
  4279.         00h reset typematic (PCjr)
  4280.         01h increase initial delay (PCjr)
  4281.         02h increase continuing delay (PCjr)
  4282.         03h increase both delays (PCjr)
  4283.         04h turn off typematic (PCjr)
  4284.         05h Set typematic rate (AT or PS/2)
  4285.     BH = 00h - 03h for delays of 250ms, 500ms, 750ms, or 1s
  4286.     BL = 00h - 1Fh for typematic rates of 30cps down to 2cps
  4287. ---------------------------------------------
  4288. INT 16 - KEYBOARD - KEYCLICK (Jr,CONV)
  4289.     AH = 04h
  4290.     AL = 00h click off
  4291.          01h click on
  4292. ---------------------------------------------
  4293. INT 16 - KEYBOARD - WRITE TO KEYBOARD BUFFER (AT model 339,XT2,XT286,PS)
  4294.     AH = 05h
  4295.     CH = scan code
  4296.     CL = character
  4297. Return: AL = 1 if buffer full
  4298. ---------------------------------------------
  4299. INT 16 - KEYBOARD - GET ENHANCED KEYSTROKE (AT model 339,XT2,XT286,PS)
  4300.     AH = 10h
  4301. Return: AH = scan code
  4302.     AL = character
  4303. ---------------------------------------------
  4304. INT 16 - KEYBOARD - CHECK ENHANCED KEYSTROKE (AT model 339,XT2,XT286,PS)
  4305.     AH = 11h
  4306. Return: ZF clear if keystroke available
  4307.         AH = scan code \ meaningless if ZF = 1
  4308.         AL = character /
  4309.     ZF set if kbd buffer empty
  4310. ---------------------------------------------
  4311. INT 16 - KEYBOARD - GET ENHANCED SHIFT FLAGS (AT model 339,XT2,XT286,PS)
  4312.     AH = 12h
  4313. Return: AL = shift flags (same as for AH=02h)
  4314.        bit 7: Ins ON
  4315.        bit 6: CapsLock ON
  4316.        bit 5: NumLock ON
  4317.        bit 4: ScrollLock ON
  4318.        bit 3: Either ALT key down
  4319.        bit 2: Either CTRL key down
  4320.        bit 1: Left shift key down
  4321.        bit 0: Right shift key down
  4322.     AH
  4323.        bit 7: SysReq key down
  4324.        bit 6: CapsLock key down
  4325.        bit 5: NumLock key down
  4326.        bit 4: ScrollLock key down
  4327.        bit 3: Right Alt key down
  4328.        bit 2: Right Ctrl key down
  4329.        bit 1: Left Alt key down
  4330.        bit 0: Right Alt key down
  4331. ---------------------------------------------
  4332. INT 16 - PC Tools v5.1 BACKTALK - UNHOOK
  4333.     AX = 6969h
  4334.     BX = 6968h
  4335. Return: resident code unhooked, but not removed from memory
  4336. ---------------------------------------------
  4337. INT 16 - PC Tools v5.1 BACKTALK - INSTALLATION CHECK
  4338.     AX = 6969h
  4339.     BX = 6969h
  4340.     DX = 0000h
  4341. Return: DX nonzero if installed
  4342.         BX = CS of resident code
  4343.         DS:SI -> ASCIZ identification string "CPoint Talk"
  4344. ---------------------------------------------
  4345. INT 16 - FAKEY.COM - INSTALLATION CHECK
  4346.     AH = 70h
  4347. Return: AX = 1954h if installed
  4348. Note:    FAKEY is a keystroke faking utility by System Enhancement Associates
  4349. ---------------------------------------------
  4350. INT 16 - FAKEY.COM - PUSH KEYSTROKES
  4351.     AH = 71h
  4352.     CX = number of keystrokes
  4353.     DS:SI -> array of words containing keystrokes to be returned by AH=00h
  4354. Note:    FAKEY is a keystroke faking utility by System Enhancement Associates
  4355. ---------------------------------------------
  4356. INT 16 - FAKEY.COM - CLEAR FAKED KEYSTROKES
  4357.     AH = 72h
  4358. Note:    FAKEY is a keystroke faking utility by System Enhancement Associates
  4359. ---------------------------------------------
  4360. INT 16 - FAKEY.COM - PLAY TONES
  4361.     AH = 73h
  4362.     CX = number of tones to play
  4363.     DS:SI -> array of tones (see below)
  4364. Note:    FAKEY is a keystroke faking utility by System Enhancement Associates
  4365.  
  4366. Format of tone array entries:
  4367. Offset    Size    Description
  4368.  00h    WORD    divisor for timer channel 2
  4369.  02h    WORD    duration in clock ticks
  4370. ---------------------------------------------
  4371. INT 16 - pcANYWHERE - SET TICK COUNT FOR SCANNING
  4372.     AH = 75h
  4373.     AL = number of ticks between checks for new screen changes
  4374. ---------------------------------------------
  4375. INT 16 - pcANYWHERE - SET ERROR CHECKING TYPE
  4376.     AH = 76h
  4377.     AL = error checking type
  4378.         00h none
  4379.         01h fast
  4380.         02h slow
  4381. ---------------------------------------------
  4382. INT 16 - pcANYWHERE - LOG OFF
  4383.     AH = 77h
  4384.     AL = mode
  4385.         00h wait for another call
  4386.         01h leave in Memory Resident Mode
  4387.         02h leave in Automatic Mode
  4388.         FFh leave in current operating mode
  4389. ---------------------------------------------
  4390. INT 16 - WATCH.COM - INSTALLATION CHECK
  4391.     AX = 7761h ('wa')
  4392. Return: AX = 5741h ('WA') if installed
  4393. Note:    WATCH.COM is part of the "TSR" package by Kim Kokkonen
  4394. ---------------------------------------------
  4395. INT 16 - PC Magazine PUSHDIR.COM - INSTALLATION CHECK
  4396.     AX = 7788h
  4397.     BX = 7789h
  4398. Return: AX = 7789h
  4399.     BX = 7788h
  4400.     DS:SI -> signature string
  4401. ---------------------------------------------
  4402. INT 16 - pcANYWHERE - CHECK STATUS
  4403.     AH = 79h
  4404. Return: AX = status
  4405.         FFFFh if resident and active
  4406.         FFFEh if resident but not active
  4407.         FFFDh if in Memory Resident mode
  4408.         FFFCh if in Automatic mode
  4409.         other value if not resident
  4410. ---------------------------------------------
  4411. INT 16 - pcANYWHERE - CANCEL SESSION
  4412.     AH = 7Ah
  4413. ---------------------------------------------
  4414. INT 16 - pcANYWHERE - SUSPEND
  4415.     AX = 7B00h
  4416. ---------------------------------------------
  4417. INT 16 - pcANYWHERE - RESUME
  4418.     AX = 7B01h
  4419. ---------------------------------------------
  4420. INT 16 - pcANYWHERE - GET PORT CONFIGURATION
  4421.     AH = 7Ch
  4422. Return: AH = port number
  4423.     AL = baud rate
  4424.         00h = 50 baud
  4425.         01h = 75 baud
  4426.         02h = 110 baud
  4427.         03h = 134.5 baud
  4428.         04h = 150 baud
  4429.         05h = 300 baud
  4430.         06h = 600 baud
  4431.         07h = 1200 baud
  4432.         08h = 1800 baud
  4433.         09h = 2000 baud
  4434.         0Ah = 2400 baud
  4435.         0Bh = 4800 baud
  4436.         0Ch = 7200 baud
  4437.         0Dh = 9600 baud
  4438.         0Eh = 19200 baud
  4439. ---------------------------------------------
  4440. INT 16 - pcANYWHERE - GET/SET TERMINAL PARAMETERS
  4441.     AH = 7Dh
  4442.     AL = subfunction
  4443.         00h set terminal parameters
  4444.         01h get terminal parameters
  4445.         02h get configuration header and terminal parameters
  4446.     DS:CX -> terminal parameter block
  4447. ---------------------------------------------
  4448. INT 16 - pcANYWHERE - COMMUNICATIONS I/O THROUGH PORT
  4449.     AH = 7Eh
  4450.     AL = subfunction
  4451.         01h port input status
  4452.         Return AX = 0 if no characer ready,
  4453.                AX = 1 if character ready
  4454.         02h port input character
  4455.         Return AL = received character
  4456.         03h port output character in CX
  4457.         11h hang up phone
  4458. ---------------------------------------------
  4459. INT 16 - pcANYWHERE - SET KEYBOARD/SCREEN MODE
  4460.     AH = 7Fh
  4461.     AL = subfunction
  4462.         00h enable remote keyboard only
  4463.         01h enable host keyboard only
  4464.         02h enable both keyboards
  4465.         08h display top 24 lines
  4466.         09h display bottom 24 lines
  4467.         10h Hayes modem
  4468.         11h other modem
  4469.         12h direct connect
  4470. ---------------------------------------------
  4471. INT 16 - MAKEY.COM - INSTALLATION CHECK
  4472.     AH = 80h
  4473. Return: AX = 1954h if installed
  4474. Note:    MAKEY is a utility by System Enhancement Associates
  4475. ---------------------------------------------
  4476. INT 16 - Compaq 386 - SET CPU SPEED
  4477.     AH = F0h
  4478.     AL = speed
  4479.         00h equivalent to 6 MHz 80286 (COMMON)
  4480.         01h equivalent to 8 MHz 80286 (FAST)
  4481.         02h full 16 MHz (HIGH)
  4482.         03h toggles between 8 MHz-equivalent and speed set by system board
  4483.         switch (AUTO or HIGH)
  4484.         08h full 16 MHz except 8 MHz-equivalent during floppy disk access
  4485.         09h specify speed directly
  4486.         CX = speed value, 1 (slowest) to 50 (full), 3 ~= 8088
  4487. ---------------------------------------------
  4488. INT 16 - Compaq 386 - READ CURRENT CPU SPEED
  4489.     AH = F1h
  4490. Return:    AL = speed code (see AH=F0h)
  4491.          if AL = 09h, CX = speed code
  4492. ---------------------------------------------
  4493. INT 16 - Compaq 386 - DETERMINE ATTACHED KEYBOARD TYPE
  4494.     AH = F2h
  4495. Return: AL = type
  4496.         00h if 11-bit AT keyboard is in use
  4497.         01h if 9-bit PC keyboard is in use 
  4498. ---------------------------------------------
  4499. INT 16 - PC Tools v5.1 DESKTOP API - ???
  4500.     AX = FFB8h
  4501.     BH = subfunction
  4502.         00h get
  4503.         Return: BL = old value of ???
  4504.         nonzero set
  4505.         BL = new value for ???
  4506. ---------------------------------------------
  4507. INT 16 - PC Tools v5.1 DESKTOP API - ???
  4508.     AX = FFB9h
  4509.     ???
  4510. Return: AX = ???
  4511.     CX = ???
  4512.     DS:SI -> ???
  4513.     ES:DI -> ???
  4514. ---------------------------------------------
  4515. INT 16 - PC Tools v5.1 DESKTOP API - ???
  4516.     AX = FFBAh
  4517.     ???
  4518. Return: ???
  4519. Note: available only when popped up
  4520. ---------------------------------------------
  4521. INT 16 - PC Tools v5.1 DESKTOP API - ???
  4522.     AX = FFBBh
  4523.     ???
  4524. Return: ???
  4525. Note: available only when popped up
  4526. ---------------------------------------------
  4527. INT 16 - PC Tools v5.1 DESKTOP API - RESTORE ORIGINAL SCREEN???
  4528.     AX = FFBCh
  4529. ---------------------------------------------
  4530. INT 16 - PC Tools v5.1 DESKTOP API - POP DOWN???
  4531.     AX = FFBDh
  4532.     ???
  4533. Return: ???
  4534. ---------------------------------------------
  4535. INT 16 - PC Tools v5.1 DESKTOP API - ???
  4536.     AX = FFBEh
  4537.     ???
  4538. Return: ???
  4539. Note: available only when popped up
  4540. ---------------------------------------------
  4541. INT 16 - PC Tools v5.1 DESKTOP API - ???
  4542.     AX = FFBFh
  4543.     ???
  4544. Return: ???
  4545. Note: available only when popped up
  4546. ---------------------------------------------
  4547. INT 16 - PC Tools v5.1 DESKTOP API - ???
  4548.     AX = FFC0h
  4549.     ???
  4550. Return: ???
  4551. Note: available only when popped up
  4552. ---------------------------------------------
  4553. INT 16 - PC Tools v5.1 DESKTOP API - ???
  4554.     AX = FFC1h
  4555.     ???
  4556. Return: ???
  4557. Note: available only when popped up
  4558. ---------------------------------------------
  4559. INT 16 - PC Tools v5.1 DESKTOP API - ???
  4560.     AX = FFC2h
  4561.     ???
  4562. Return: ???
  4563. Note: available only when popped up
  4564. ---------------------------------------------
  4565. INT 16 - PC Tools v5.1 DESKTOP API - ???
  4566.     AX = FFC3h
  4567.     ???
  4568. Return: ???
  4569. Note: available only when popped up
  4570. ---------------------------------------------
  4571. INT 16 - PC Tools v5.1 DESKTOP API - ???
  4572.     AX = FFC4h
  4573.     ???
  4574. Return: ???
  4575. Note: available only when popped up
  4576. ---------------------------------------------
  4577. INT 16 - PC Tools v5.1 DESKTOP API - ???
  4578.     AX = FFC5h
  4579. Return: BL = ???
  4580. Note: available only when popped up
  4581. ---------------------------------------------
  4582. INT 16 - PC Tools v5.1 DESKTOP API - SET ???
  4583.     AX = FFC6h
  4584.     BL = new value for ???
  4585. ---------------------------------------------
  4586. INT 16 - PC Tools v5.1 DESKTOP API - ???
  4587.     AX = FFC7h
  4588.     ???
  4589. Return: ???
  4590. Note: screen swapping???
  4591. ---------------------------------------------
  4592. INT 16 - PC Tools v5.1 DESKTOP API - GET ???
  4593.     AX = FFC8h
  4594. Return: DS:SI -> ???
  4595. ---------------------------------------------
  4596. INT 16 - PC Tools v5.1 DESKTOP API - ???
  4597.     AX = FFC9h
  4598.     SI = ???
  4599.     CX = ???
  4600. Return: ???
  4601. Note: available only when popped up
  4602. ---------------------------------------------
  4603. INT 16 - PC Tools v5.1 DESKTOP API - ???
  4604.     AX = FFCAh
  4605.     DX = ???
  4606. Return: ???
  4607. Note: available only when popped up
  4608. ---------------------------------------------
  4609. INT 16 - PC Tools v5.1 DESKTOP API - ???
  4610.     AX = FFCBh
  4611.     DX = ???
  4612. Return: ???
  4613. Note: available only when popped up
  4614. ---------------------------------------------
  4615. INT 16 - PC Tools v5.1 DESKTOP API - DISPLAY ASCIZ STRING
  4616.     AX = FFCCh
  4617.     DS:SI -> ASCIZ string
  4618. Return: AX = ???
  4619.     CX = ???
  4620.     ES:DI -> address past last character displayed
  4621. ---------------------------------------------
  4622. INT 16 - PC Tools v5.1 DESKTOP API - ???
  4623.     AX = FFCDh
  4624.     DS:DX -> ???
  4625. Return: ???
  4626. Note: available only when popped up
  4627. ---------------------------------------------
  4628. INT 16 - PC Tools v5.1 DESKTOP API - SET ??? DELAYS
  4629.     AX = FFCEh
  4630.     CX = ???
  4631. Return: nothing???
  4632. ---------------------------------------------
  4633. INT 16 - PC Tools v5.1 DESKTOP API - ???
  4634.     AX = FFCFh
  4635.     ???
  4636. Return: ???
  4637. Note: available only when popped up
  4638. ---------------------------------------------
  4639. INT 16 - PC Tools v5.1 DESKTOP API - ???
  4640.     AX = FFD0h
  4641.     ???
  4642. Return: ???
  4643. Note: available only when popped up
  4644. ---------------------------------------------
  4645. INT 16 - PC Tools v5.1 DESKTOP API - ???
  4646.     AX = FFD1h
  4647.     ???
  4648. Return: ???
  4649. Note: available only when popped up
  4650. ---------------------------------------------
  4651. INT 16 - PC Tools v5.1 DESKTOP API - ???
  4652.     AX = FFD2h
  4653.     BX = ???
  4654. Return: ???
  4655. Note: available only when popped up
  4656. ---------------------------------------------
  4657. INT 16 - PC Tools v5.1 DESKTOP API - ???
  4658.     AX = FFD3h
  4659.     ???
  4660. Return: ???
  4661. ---------------------------------------------
  4662. INT 16 - PC Tools v5.1 DESKTOP API - CREATE/OPEN/DELETE FILE
  4663.     AX = FFD4h
  4664.     BH = 3Ch create file
  4665.         CX = file attributes
  4666.          3Dh open file
  4667.          41h delete file
  4668.     BL = access mode
  4669.          00h read only
  4670.          01h write only
  4671.          02h read/write
  4672.     DS:SI -> ASCIZ filename
  4673. Return: BX = file handle
  4674.         0000h on error
  4675. ---------------------------------------------
  4676. INT 16 - PC Tools v5.1 DESKTOP API - ???
  4677.     AX = FFD5h
  4678.     ???
  4679. Return: ???
  4680. Note: available only when popped up
  4681. ---------------------------------------------
  4682. INT 16 - PC Tools v5.1 DESKTOP API - ???
  4683.     AX = FFD6h
  4684.     ???
  4685. Return: ???
  4686. Note: available only when popped up
  4687. ---------------------------------------------
  4688. INT 16 - PC Tools v5.1 DESKTOP API - ???
  4689.     AX = FFD7h
  4690.     ???
  4691. Return: ???
  4692. Note: available only when popped up
  4693. ---------------------------------------------
  4694. INT 16 - PC Tools v5.1 DESKTOP API - SAFE CREATE FILE
  4695.     AX = FFD8h
  4696.     DS:BX -> ASCIZ filename
  4697. Return: BX = file handle
  4698.         0000h on error
  4699. Note: pops up confirmation menu if file already exists
  4700.       only when popped up???
  4701. ---------------------------------------------
  4702. INT 16 - PC Tools v5.1 DESKTOP API - ???
  4703.     AX = FFD9h
  4704.     ???
  4705. Return: ???
  4706. Note: available only when popped up
  4707. ---------------------------------------------
  4708. INT 16 - PC Tools v5.1 DESKTOP API - ???
  4709.     AX = FFDAh
  4710.     DS:SI -> ???
  4711. Return: DS:SI -> ???
  4712. ---------------------------------------------
  4713. INT 16 - PC Tools v5.1 DESKTOP API - ???
  4714.     AX = FFDBh
  4715.     ???
  4716. Return: ???
  4717. Note: available only when popped up
  4718. ---------------------------------------------
  4719. INT 16 - PC Tools v5.1 DESKTOP API - UNHOOK
  4720.     AX = FFDCh
  4721. Return: interrupt vectors 09h, 16h, 1Ch, and 21h restored to original values
  4722. ---------------------------------------------
  4723. INT 16 - PC Tools v5.1 PCShell API - INSTALLATION CHECK
  4724.     AX = FFDDh
  4725.     BX = 0000h
  4726. Return: CX = 5555h 
  4727.     DX = 5555h if PCShell installed in resident mode
  4728. ---------------------------------------------
  4729. INT 16 - PC Tools v5.1 PCShell API - REQUEST POP-UP
  4730.     AX = FFDDh
  4731.     BX = 0001h
  4732. ---------------------------------------------
  4733. INT 16 - PC Tools v5.1 PCShell API - GET ???
  4734.     AX = FFDDh
  4735.     BX = 0002h
  4736. Return: AL = 
  4737.         00h ???
  4738.         01h ???
  4739. ---------------------------------------------
  4740. INT 16 - PC Tools v5.1 PCShell API - REQUEST POP-UP
  4741.     AX = FFDDh
  4742.     BX = 0003h
  4743. ---------------------------------------------
  4744. INT 16 - PC Tools v5.1 PCShell API - ???
  4745.     AX = FFDDh
  4746.     BX = 0004h
  4747.     ???
  4748. Return: DS:SI -> ???
  4749. ---------------------------------------------
  4750. INT 16 - PC Tools v5.1 PCShell API - ???
  4751.     AX = FFDDh
  4752.     BX = 0005h
  4753.     ???
  4754. Return: ???
  4755. ---------------------------------------------
  4756. INT 16 - PC Tools v5.1 PCShell API - ???
  4757.     AX = FFDDh
  4758.     BX = 0006h
  4759.     ???
  4760. Return: ???
  4761. ---------------------------------------------
  4762. INT 16 - PC Tools v5.1 PCShell API - ???
  4763.     AX = FFDDh
  4764.     BX = 0007h
  4765.     ???
  4766. Return: ???
  4767. ---------------------------------------------
  4768. INT 16 - PC Tools v5.1 PCShell API - ???
  4769.     AX = FFDDh
  4770.     BX = 0008h
  4771.     ???
  4772. Return: ???
  4773. ---------------------------------------------
  4774. INT 16 - PC Tools v5.1 DESKTOP API - ???
  4775.     AX = FFDEh
  4776.     DS:DX -> ???
  4777. Return: ???
  4778. Note: available only when popped up
  4779. ---------------------------------------------
  4780. INT 16 - PC Tools v5.1 DESKTOP API - ???
  4781.     AX = FFDFh
  4782.     ???
  4783. Return: ???
  4784. ---------------------------------------------
  4785. INT 16 - PC Tools v5.1 DESKTOP API - ???
  4786.     AX = FFE0h
  4787.     CX = ???
  4788.     DX = ???
  4789. Return: ???
  4790. ---------------------------------------------
  4791. INT 16 - PC Tools v5.1 DESKTOP API - BEEP
  4792.     AX = FFE1h
  4793. ---------------------------------------------
  4794. INT 16 - PC Tools v5.1 DESKTOP API - ???
  4795.     AX = FFE2h
  4796.     DX = ???
  4797. Return: ???
  4798. Note: available only when popped up
  4799. ---------------------------------------------
  4800. INT 16 - PC Tools v5.1 DESKTOP API - ???
  4801.     AX = FFE3h
  4802.     BL = ???
  4803. Return: ???
  4804. ---------------------------------------------
  4805. INT 16 - PC Tools v5.1 DESKTOP API - ???
  4806.     AX = FFE4h
  4807.     DX = segment of ???
  4808. Return: ???
  4809. Note: available only when popped up
  4810. ---------------------------------------------
  4811. INT 16 - PC Tools v5.1 DESKTOP API - ???
  4812.     AX = FFE5h
  4813.     DS:SI -> wildcard filename???
  4814.     DX = ???
  4815. Return: AX = ???
  4816. Note: available only when popped up
  4817. ---------------------------------------------
  4818. INT 16 - PC Tools v5.1 DESKTOP API - ???
  4819.     AX = FFE6h
  4820.     DS:SI -> ???
  4821. Return: AX = ???
  4822. ---------------------------------------------
  4823. INT 16 - PC Tools v5.1 DESKTOP API - ???
  4824.     AX = FFE7h
  4825.     BX = segment of ???
  4826. Return: ???
  4827. Note: available only when popped up
  4828. ---------------------------------------------
  4829. INT 16 - PC Tools v5.1 DESKTOP API - DISPLAY NUMBER
  4830.     AX = FFE8h
  4831.     CX = number
  4832.     DH = attribute
  4833.     DS:SI -> destination for ASCII number
  4834. Return: DS:SI buffer filled in with alternating characters and attributes
  4835. ---------------------------------------------
  4836. INT 16 - PC Tools v5.1 DESKTOP API - ???
  4837.     AX = FFE9h
  4838.     ???
  4839. Return: ???
  4840. Note: available only when popped up
  4841. ---------------------------------------------
  4842. INT 16 - PC Tools v5.1 DESKTOP API - DISPLAY COUNTED STRING
  4843.     AX = FFEAh
  4844.     DS:SI -> counted string (count byte followed by string)
  4845. Return: ???
  4846. Note: available only when popped up
  4847. ---------------------------------------------
  4848. INT 16 - PC Tools v5.1 DESKTOP API - ???
  4849.     AX = FFEBh
  4850.     ???
  4851. Return: ???
  4852. ---------------------------------------------
  4853. INT 16 - PC Tools v5.1 DESKTOP API - ???
  4854.     AX = FFECh
  4855.     DS:SI -> FAR routine to ???
  4856.     BX = ???
  4857. Return: AX = ???
  4858. ---------------------------------------------
  4859. INT 16 - PC Tools v5.1 DESKTOP API - ???
  4860.     AX = FFEDh
  4861. Return: AX = ???
  4862. ---------------------------------------------
  4863. INT 16 - PC Tools v5.1 DESKTOP API - ???
  4864.     AX = FFEEh
  4865.     SI = ???
  4866. Return: ???
  4867. Note: available only when popped up
  4868. ---------------------------------------------
  4869. INT 16 - PC Tools v5.1 DESKTOP API - INSTALLATION CHECK
  4870.     AX = FFEFh
  4871.     CX = 0000h
  4872. Return: CX = ABCDh if PC Tools DESKTOP.EXE installed
  4873.         BX = segment of resident portion
  4874.         AX = ???
  4875. ---------------------------------------------
  4876. INT 16 - PC Tools v5.1 DESKTOP API - ???
  4877.     AX = FFF0h
  4878.     DX = ???
  4879. Return: ???
  4880. Note: available only when popped up
  4881. ---------------------------------------------
  4882. INT 16 - PC Tools v5.1 DESKTOP API - ALTERNATE INSTALLATION CHECK
  4883.     AX = FFF1h
  4884.     BX = 0000h  leave ??? flag as is
  4885.         nonzero set ??? flag
  4886. Return: CX = 5555h if installed
  4887.     DX = 5555h
  4888. ---------------------------------------------
  4889. INT 16 - PC Tools v5.1 DESKTOP API - ???
  4890.     AX = FFF2h
  4891.     ???
  4892. Return: ???
  4893. Note: available only when popped up
  4894. ---------------------------------------------
  4895. INT 16 - PC Tools v5.1 DESKTOP API - ???
  4896.     AX = FFF3h
  4897.     ???
  4898. Return: ???
  4899. ---------------------------------------------
  4900. INT 16 - PC Tools v5.1 DESKTOP API - ???
  4901.     AX = FFF4h
  4902.     ???
  4903. Return: ???
  4904. Note: available only when popped up
  4905. ---------------------------------------------
  4906. INT 16 - PC Tools v5.1 DESKTOP API - GET SCREEN ATTRIBUTE ARRAY
  4907.     AX = FFF5h
  4908. Return: ES:BX -> array of screen attributes 
  4909.         00h    BYTE  normal characters on desktop menu
  4910.         01h    BYTE  highlighted characters on desktop menu
  4911.         02h    BYTE 
  4912.         03h    BYTE
  4913.         etc.
  4914. ---------------------------------------------
  4915. INT 16 - PC Tools v5.1 DESKTOP API - ???
  4916.     AX = FFF6h
  4917.     DS = ???
  4918.     BX = ???
  4919.     DX = ???
  4920. Return: ???
  4921. Note: available only when popped up
  4922. ---------------------------------------------
  4923. INT 16 - PC Tools v5.1 DESKTOP API - ???
  4924.     AX = FFF7h
  4925.     SI = ???
  4926. Return: ???
  4927. ---------------------------------------------
  4928. INT 16 - PC Tools v5.1 DESKTOP API - ???
  4929.     AX = FFF8h
  4930.     DS:SI -> ???
  4931.     BX = ???
  4932. Return: ???
  4933. ---------------------------------------------
  4934. INT 16 - PC Tools v5.1 DESKTOP API - ???
  4935.     AX = FFF9h
  4936.     ES:BX -> FAR routine to ???
  4937. Return: ???
  4938. Note: available only when popped up
  4939. ---------------------------------------------
  4940. INT 16 - PC Tools v5.1 DESKTOP API - ???
  4941.     AX = FFFAh
  4942. Return: ???
  4943. ---------------------------------------------
  4944. INT 16 - PC Tools v5.1 DESKTOP API - ???
  4945.     AX = FFFBh
  4946. Return: ???
  4947. ---------------------------------------------
  4948. INT 16 - PC Tools v5.1 DESKTOP API - GET ???
  4949.     AX = FFFCh
  4950. Return: ES:BX = ???
  4951.     DS:DX = original INT 9 vector
  4952. ---------------------------------------------
  4953. INT 16 - PC Tools v5.1 DESKTOP API - ???
  4954.     AX = FFFDh
  4955.     ???
  4956. Return: ???
  4957. ---------------------------------------------
  4958. INT 16 - PC Tools v5.1 DESKTOP API - SHOW MOUSE CURSOR
  4959.     AX = FFFEh
  4960. ---------------------------------------------
  4961. INT 16 - PC Tools v5.1 DESKTOP API - HIDE MOUSE CURSOR
  4962.     AX = FFFFh
  4963. ---------------------------------------------
  4964. INT 17 - PRINTER - OUTPUT CHARACTER
  4965.     AH = 00h
  4966.     AL = character
  4967.     DX = printer port (0-3)
  4968. Return: AH = status bits
  4969.         0 = time out
  4970.         1 = unused
  4971.         2 = unused
  4972.         3 = I/O error
  4973.         4 = selected
  4974.         5 = out of paper
  4975.         6 = acknowledge
  4976.         7 = not busy
  4977. ---------------------------------------------
  4978. INT 17 - PRINTER - INITIALIZE
  4979.     AH = 01h
  4980.     DX = printer port (0-3)
  4981. Return: AH = status (see AH=00h)
  4982. ---------------------------------------------
  4983. INT 17 - PRINTER - GET STATUS
  4984.     AH = 02h
  4985.     DX = printer port (0-3)
  4986. Return: AH = status (see AH=00h)
  4987. ---------------------------------------------
  4988. INT 18 - TRANSFER TO ROM BASIC
  4989.    causes transfer to ROM-based BASIC (IBM-PC)
  4990.    often reboots a compatible; often has no effect at all
  4991. ---------------------------------------------
  4992. INT 19 - DISK BOOT
  4993.    causes reboot of disk system (no memory test performed)
  4994. ---------------------------------------------
  4995. INT 1A - CLOCK - GET TIME OF DAY
  4996.     AH = 00h
  4997. Return: CX:DX = clock count
  4998.     AL = 00h if clock was read or written (via AH=0,1) within the current
  4999.          24-hour period
  5000.          Otherwise, AL > 0
  5001. ---------------------------------------------
  5002. INT 1A - CLOCK - SET TIME OF DAY
  5003.     AH = 01h
  5004.     CX:DX = clock count
  5005. Return: time of day set
  5006. ---------------------------------------------
  5007. INT 1A - CLOCK - READ REAL TIME CLOCK (AT,XT286,CONV,PS)
  5008.     AH = 02h
  5009. Return: CH = hours in BCD
  5010.     CL = minutes in BCD
  5011.     DH = seconds in BCD
  5012. ---------------------------------------------
  5013. INT 1A - CLOCK - SET REAL TIME CLOCK (AT,XT286,CONV,PS)
  5014.     AH = 03h
  5015.     CH = hours in BCD
  5016.     CL = minutes in BCD
  5017.     DH = seconds in BCD
  5018.     DL = 01h if daylight savings, 00h if standard time
  5019. Return: CMOS clock set
  5020. ---------------------------------------------
  5021. INT 1A - CLOCK - READ DATE FROM REAL TIME CLOCK (AT,XT286,CONV,PS)
  5022.     AH = 04h
  5023. Return: DL = day in BCD
  5024.     DH = month in BCD
  5025.     CL = year in BCD
  5026.     CH = century (19h or 20h)
  5027. ---------------------------------------------
  5028. INT 1A - CLOCK - SET DATE IN REAL TIME CLOCK (AT,XT286,CONV,PS)
  5029.     AH = 05h
  5030.     DL = day in BCD
  5031.     DH = month in BCD
  5032.     CL = year in BCD
  5033.     CH = century (19h or 20h)
  5034. Return: CMOS clock set
  5035. ---------------------------------------------
  5036. INT 1A - CLOCK - SET ALARM (AT,XT286,CONV,PS)
  5037.     AH = 06h
  5038.     CH = hours in BCD
  5039.     CL = minutes in BCD
  5040.     DH = seconds in BCD
  5041. Return: CF set if alarm already set or clock inoperable
  5042.     INT 4Ah will be called when alarm goes off, every 24 hours until reset
  5043. ---------------------------------------------
  5044. INT 1A - CLOCK - RESET ALARM (AT,XT286,CONV,PS)
  5045.     AH = 07h
  5046. Return: alarm disabled
  5047. ---------------------------------------------
  5048. INT 1A - CLOCK - SET RTC ACTIVATED POWER ON MODE (CONVERTIBLE)
  5049.     AH = 08h
  5050.     CH = hours in BCD
  5051.     CL = minutes in BCD
  5052.     DH = seconds in BCD
  5053. ---------------------------------------------
  5054. INT 1A - CLOCK - READ RTC ALARM TIME AND STATUS (CONV,PS30)
  5055.     AH = 09h
  5056. Return: CH = hours in BCD
  5057.     CL = minutes in BCD
  5058.     DH = seconds in BCD
  5059.     DL = alarm status
  5060.         00h alarm not enabled
  5061.         01h alarm enabled but will not power up system
  5062.         02h alarm will power up system
  5063. ---------------------------------------------
  5064. INT 1A - CLOCK - READ SYSTEM-TIMER DAY COUNTER (XT2,PS)
  5065.     AH = 0Ah
  5066. Return: CF set on error
  5067.     CX = count of days since Jan 1,1980
  5068. ---------------------------------------------
  5069. INT 1A - CLOCK - SET SYSTEM-TIMER DAY COUNTER (XT2,PS)
  5070.     AH = 0Bh
  5071.     CX = count of days since Jan 1,1980
  5072. Return: CF set on error
  5073. ---------------------------------------------
  5074. INT 1A - PCjr - SET UP SOUND MULTIPLEXOR
  5075.     AH = 80h
  5076.     AL = 00h source is 8253 channel 2
  5077.          01h source is cassette input
  5078.          02h source is I/O channel "Audio IN"
  5079.          03h source is sound generator chip
  5080. ---------------------------------------------
  5081. INT 1A - AT&T 6300 - READ TIME AND DATE
  5082.     AH = FEh
  5083. Return: BX = day count (1 = Jan 1, 1984)
  5084.     CH = hour
  5085.     CL = minute
  5086.     DH = second
  5087.     DL = hundredths
  5088. ---------------------------------------------
  5089. INT 1B - CTRL-BREAK KEY
  5090.    This interrupt is called when the keyboard scanner of the IBM
  5091.    machines detects CTRL and BREAK pressed at the same time. It
  5092.    normally points to a short routine in DOS which sets the
  5093.    Ctrl-C flag, thus invoking INT 23h the next time DOS checks
  5094.    for Ctrl-C.
  5095. ---------------------------------------------
  5096. INT 1C - CLOCK TICK
  5097.    This interrupt is called (in the IBM) at the end of each time-update
  5098.    operation by the time-of-day routines.  It normally points to an IRET.
  5099. ---------------------------------------------
  5100. INT 1D - (NOT a vector!) 6845 VIDEO INIT TABLES
  5101.  
  5102. Format of video init tables:
  5103. Offset    Size    Description
  5104.  00h 16 BYTEs    table for modes 0 and 1        \
  5105.  10h 16 BYTEs    table for modes 2 and 3         \  each table contains values
  5106.  20h 16 BYTEs    table for modes 4, 5, and 6     /  for first sixteen 6485 regs
  5107.  30h 16 BYTEs    table for mode 7        /
  5108.  40h    WORD    size of video RAM for modes 0 and 1
  5109.  42h    WORD    size of video RAM for modes 2 and 3
  5110.  44h    WORD    size of video RAM for modes 4 and 5
  5111.  46h    WORD    size of video RAM for modes 6 and 7
  5112.  48h  8 BYTEs    number of colums in each of modes 0 through 7
  5113.  50h  8 BYTEs    video controller mode byte for each mode
  5114. ---------------------------------------------
  5115. INT 1E - (NOT a vector!) DISKETTE PARAMS (BASE TABLE)
  5116.     default parameters at F000h:EFC7h in PC and most compatibles
  5117.  
  5118. Format of diskette parameters:
  5119. Offset    Size    Description
  5120.  00h    BYTE    step rate & head unload times
  5121.  01h    BYTE    head load time & DMA
  5122.  02h    BYTE    motor off time in clock ticks (36 or 37 typical)
  5123.  03h    BYTE    sector size in bytes (0->128, 1->256, 2->512, 3->1024)
  5124.  04h    BYTE    last sector number (8 or 9 typical)
  5125.  05h    BYTE    inter-sector gap size on read/write (42 typical)
  5126.  06h    BYTE    data transfer length (255 typical)
  5127.  07h    BYTE    inter-sector gap size on format (80 typical)
  5128.  08h    BYTE    sector fill on format (F6h typical)
  5129.  09h    BYTE    head-settle time ms (typical 25, 1.10->0, 2.10->15, 3.10->1)
  5130.  0Ah    BYTE    motor start-up time (1/8 secs) (typical 4, 2.10->2)
  5131. ---------------------------------------------
  5132. INT 1F - (NOT a vector!) GRAPHICS SET 2
  5133.     pointer to bitmaps for high 128 chars
  5134. ---------------------------------------------
  5135. INT 20 - Minix - SEND/RECEIVE MESSAGE
  5136.     AX = process ID of other process
  5137.     BX -> message
  5138.     CX = 1 send
  5139.          2 receive
  5140.          3 send&receive
  5141. Note: the message contains the system call number (numbered as in V7 Unix(tm))
  5142.       and the call parameters
  5143. ---------------------------------------------
  5144. INT 20 - DOS - PROGRAM TERMINATION
  5145. returns to DOS--identical to INT 21/AH=00h
  5146. ---------------------------------------------
  5147. INT 21 - DOS - PROGRAM TERMINATION
  5148.     AH = 00h
  5149. Return: never
  5150. ---------------------------------------------
  5151. INT 21 - DOS - KEYBOARD INPUT
  5152.     AH = 01h
  5153. Return: AL = character read
  5154. Note: ^C/^Break are checked, and INT 23h executed if read
  5155.       character is echoed to standard output
  5156. ---------------------------------------------
  5157. INT 21 - DOS - DISPLAY OUTPUT
  5158.     AH = 02h
  5159.     DL = character to send to standard output
  5160. Note: ^C/^Break are checked, and INT 23h executed if pressed
  5161. ---------------------------------------------
  5162. INT 21 - DOS - AUX INPUT
  5163.     AH = 03h
  5164. Return: AL = character read
  5165. ---------------------------------------------
  5166. INT 21 - DOS - AUX OUTPUT
  5167.     AH = 04h
  5168.     DL = character to send
  5169. ---------------------------------------------
  5170. INT 21 - DOS - PRINTER OUTPUT
  5171.     AH = 05h
  5172.     DL = character to print
  5173. ---------------------------------------------
  5174. INT 21 - DOS - DIRECT CONSOLE I/O CHARACTER OUTPUT
  5175.     AH = 06h
  5176.     DL = character <> FFh
  5177. ---------------------------------------------
  5178. INT 21 - DOS - DIRECT CONSOLE I/O CHARACTER INPUT
  5179.     AH = 06h
  5180.     DL = 0FFh
  5181. Return: ZF set     = no character
  5182.     ZF clear = character recieved
  5183.           AL = character
  5184. Notes: Character is echoed to STDOUT if received.
  5185.        ^C/^Break are NOT checked
  5186. ---------------------------------------------
  5187. INT 21 - DOS - DIRECT STDIN INPUT, NO ECHO
  5188.     AH = 07h
  5189. Note: same as function 06h for input but char not echoed
  5190. ---------------------------------------------
  5191. INT 21 - DOS - KEYBOARD INPUT, NO ECHO
  5192.     AH = 08h
  5193. Return: AL = character
  5194. Note: same as function 07h, but ^C/^Break are checked
  5195. ---------------------------------------------
  5196. INT 21 - DOS - PRINT STRING
  5197.     AH = 09h
  5198.     DS:DX -> string terminated by "$"
  5199. Note: ^C/^Break checked, and INT 23h called if pressed
  5200. ---------------------------------------------
  5201. INT 21 - DOS - BUFFERED KEYBOARD INPUT
  5202.     AH = 0Ah
  5203.     DS:DX -> buffer
  5204. Note: first byte of buffer must contain maximum length
  5205.       on entry, second byte contains actual length of previous line which may
  5206.     be recalled with the DOS line-editing commands
  5207.       on return the second byte contains actual length, third and
  5208.     subsequent bytes contain the input line
  5209. ---------------------------------------------
  5210. INT 21 - DOS - CHECK STANDARD INPUT STATUS
  5211.     AH = 0Bh
  5212. Return: AL = FFh if character available
  5213.          00h if no character
  5214. Note: ^C/^Break checked, and INT 23h called if pressed
  5215. ---------------------------------------------
  5216. INT 21 - DOS - CLEAR KEYBOARD BUFFER
  5217.     AH = 0Ch
  5218.     AL must be 1, 6, 7, 8, or 0Ah.
  5219. Notes: Flushes all typeahead input, then executes function specified by AL
  5220.        (effectively moving it to AH and repeating the INT 21 call).
  5221.        If AL contains a value not in the list above, the keyboard buffer is
  5222.        flushed and no other action is taken.
  5223. ---------------------------------------------
  5224. INT 21 - DOS - DISK RESET
  5225.     AH = 0Dh
  5226. Note: Flushes all disk buffers.
  5227. ---------------------------------------------
  5228. INT 21 - DOS - SELECT DISK
  5229.     AH = 0Eh
  5230.     DL = new default drive number (0 = A, 1 = B, etc.)
  5231. Return: AL = number of logical drives
  5232. ---------------------------------------------
  5233. INT 21 - DOS - OPEN DISK FILE
  5234.     AH = 0Fh
  5235.     DS:DX -> FCB (see below)
  5236. Return: AL = 00h file found
  5237.          FFh file not found
  5238. Note: (DOS 3+) file opened in compatibility mode
  5239.  
  5240. Format of File Control Block:
  5241. Offset    Size    Description
  5242.  -7    BYTE    extended FCB if FFh
  5243.  -6   5 BYTEs    reserved
  5244.  -1    BYTE    file attribute if extended FCB
  5245.  00h    BYTE    drive number (0 = default, 1 = A, etc)
  5246.  01h  8 BYTEs    blank-padded file name 
  5247.  09h  3 BYTEs    blank-padded file extension
  5248.  0Ch    WORD    current block number
  5249.  0Eh    WORD    logical record size
  5250.  10h    DWORD    file size
  5251.  14h    WORD    date of last write (see AX=5700h)
  5252.  16h    WORD    time of last write (see AX=5700h)
  5253.  18h  8 BYTEs    reserved (see below)
  5254.  20h    BYTE    record within current block
  5255.  21h    DWORD    random access record number (if record size is > 64 bytes, high
  5256.         byte is omitted)
  5257.  
  5258. Format of reserved field for DOS 3.x:
  5259. Offset    Size    Description
  5260.  18h    BYTE    number of system file table entry for file
  5261.  19h    BYTE    attributes
  5262.         bits 7,6: 00 = SHARE.EXE not loaded, disk file
  5263.               01 = SHARE.EXE not loaded, character device
  5264.               10 = SHARE.EXE loaded, remote file
  5265.               11 = SHARE.EXE loaded, local file
  5266.         bits 5-0: low six bits of device attribute word
  5267. ---SHARE.EXE loaded, local file---
  5268.  1Ah    WORD    starting cluster of file
  5269.  1Ch    WORD    offset within SHARE of sharing record (see AH=52h)
  5270.  1Eh    BYTE    file attribute
  5271.  1Fh    BYTE    ???
  5272. ---SHARE.EXE loaded, remote file---
  5273.  1Ah    WORD    number of sector containing directory entry
  5274.  1Ch    WORD    relative cluster within file of last cluster read
  5275.  1Eh    BYTE    absolute cluster number of last cluster read
  5276.  1Fh    BYTE    ???
  5277. ---SHARE.EXE not loaded---
  5278.  1Ah    BYTE    (low byte of device attribute word AND 0Ch) OR open mode
  5279.  1Bh    WORD    starting cluster of file
  5280.  1Dh    WORD    number of sector containing directory entry
  5281.  1Fh    BYTE    number of directory entry within sector
  5282. Note: if FCB opened on character device, DWORD at 1Ah is set to the address
  5283.     of the device driver header, then the BYTE at 1Ah is overwritten.
  5284. ---------------------------------------------
  5285. INT 21 - DOS - CLOSE DISK FILE
  5286.     AH = 10h
  5287.     DS:DX -> FCB (see AH=0Fh)
  5288. Return: AL = 00h directory update successful
  5289.          FFh file not found in directory
  5290. ---------------------------------------------
  5291. INT 21 - DOS - SEARCH FIRST USING FCB
  5292.     AH = 11h
  5293.     DS:DX -> FCB (see AH=0Fh)
  5294. Return: AL = status
  5295.         00h file found
  5296.         [DTA] = unopened FCB for file that was found
  5297.         FFh file not found
  5298. ---------------------------------------------
  5299. INT 21 - DOS - SEARCH NEXT USING FCB
  5300.     AH = 12h
  5301.     DS:DX -> FCB (see AH=0Fh)
  5302. Return: AL = status
  5303.         00h file found
  5304.         [DTA] = unopened FCB for file that was found
  5305.         FFh file not found
  5306. ---------------------------------------------
  5307. INT 21 - DOS - DELETE FILE via FCB
  5308.     AH = 13h
  5309.     DS:DX -> FCB (see AH=0Fh) with filename field filled with template for
  5310.          deletion ('?' wildcard allowed, but not '*')
  5311. Return: AL = status
  5312.         00h file found
  5313.         FFh file not found
  5314. ---------------------------------------------
  5315. INT 21 - DOS - SEQUENTIAL DISK FILE READ
  5316.     AH = 14h
  5317.     DS:DX -> FCB (see AH=0Fh)
  5318. Return: AL = status
  5319.         00h successful read
  5320.         01h end of file
  5321.         02h data transfer area too small
  5322.         03h partial record, EOF
  5323. ---------------------------------------------
  5324. INT 21 - DOS - SEQUENTIAL DISK RECORD WRITE
  5325.     AH = 15h
  5326.     DS:DX -> FCB (see AH=0Fh)
  5327. Return: AL = status
  5328.         00h successful write
  5329.         01h disk full
  5330.         02h data transfer area too small
  5331. ---------------------------------------------
  5332. INT 21 - DOS - CREATE A DISK FILE
  5333.     AH = 16h
  5334.     DS:DX -> FCB (see AH=0Fh)
  5335. Return: AL = status
  5336.         00h successful creation
  5337.         FFh directory full
  5338. Note: if file already exists, it is truncated to zero length
  5339. ---------------------------------------------
  5340. INT 21 - DOS - RENAME FILE via FCB
  5341.     AH = 17h
  5342.     DS:DX -> FCB (see AH=0Fh)
  5343.     FCB contains new name starting at byte 17h.
  5344. Return: AL = status
  5345.         00h file found
  5346.         FFh file not found
  5347. ---------------------------------------------
  5348. INT 21 - DOS internal - UNUSED
  5349.     AH = 18h
  5350. Return: AL = 00h
  5351. ---------------------------------------------
  5352. INT 21 - DOS - GET DEFAULT DISK NUMBER
  5353.     AH = 19h
  5354. Return: AL = current drive number (letter - 'A')
  5355. ---------------------------------------------
  5356. INT 21 - DOS - SET DISK TRANSFER AREA ADDRESS
  5357.     AH = 1Ah
  5358.     DS:DX -> disk transfer buffer
  5359. ---------------------------------------------
  5360. INT 21 - DOS - ALLOCATION TABLE INFORMATION
  5361.     AH = 1Bh
  5362. Return: DS:BX -> FAT ID byte for default drive
  5363.     DX = number of allocation units on disk
  5364.     AL = number of sectors per allocation unit (cluster)
  5365.     CX = number of bytes per sector
  5366. ---------------------------------------------
  5367. INT 21 - DOS - ALLOCATION TABLE INFORMATION FOR SPECIFIC DEVICE
  5368.     AH = 1Ch
  5369.     DL = drive number to check
  5370. Return: DS:BX -> FAT ID byte
  5371.     DX = number of allocation units on disk
  5372.     AL = number of sectors per allocation unit (cluster)
  5373.     CX = number of bytes per sector
  5374. ---------------------------------------------
  5375. INT 21 - DOS internal - UNUSED
  5376.     AH = 1Dh
  5377. Return: AL = 00h
  5378. ---------------------------------------------
  5379. INT 21 - DOS internal - UNUSED
  5380.     AH = 1Eh
  5381. Return: AL = 00h
  5382. ---------------------------------------------
  5383. INT 21 - DOS internal - GET DEFAULT DRIVE PARAMETER BLOCK
  5384.     AH = 1Fh
  5385. Return: AL = 00h No Error
  5386.          FFh Error
  5387.     DS:BX -> drive parameter block
  5388. Note: for DOS 2+, this just invokes function 32h with DL = 0
  5389. ---------------------------------------------
  5390. INT 21 - DOS internal - UNUSED
  5391.     AH = 20h
  5392. Return: AL = 00h
  5393. ---------------------------------------------
  5394. INT 21 - DOS - RANDOM DISK RECORD READ
  5395.     AH = 21h
  5396.     DS:DX -> FCB (see AH=0Fh)
  5397. Return: AL = status
  5398.         00h successful read
  5399.         01h end of file
  5400.         02h data transfer area too small
  5401.         03h partial record, EOF
  5402. ---------------------------------------------
  5403. INT 21 - DOS - RANDOM DISK RECORD WRITE
  5404.     AH = 22h
  5405.     DS:DX -> FCB (see AH=0Fh)
  5406. Return: AL = status (see AH=21h)
  5407. ---------------------------------------------
  5408. INT 21 - DOS - GET FILE SIZE
  5409.     AH = 23h
  5410.     DS:DX -> unopened FCB (see AH=0Fh) with filename and record size
  5411.          fields initialized
  5412. Return: AL = status
  5413.         00h file found
  5414.         FFh file not found
  5415. Note: FCB's random-record field set to number of records (rounded up)
  5416. ---------------------------------------------
  5417. INT 21 - DOS - SET RANDOM RECORD FIELD
  5418.     AH = 24h
  5419.     DS:DX -> open FCB (see AH=0Fh)
  5420. Return: Random Record Field of FCB is set to be same as Current Block
  5421.     and Current Record.
  5422. ---------------------------------------------
  5423. INT 21 - DOS - SET INTERRUPT VECTOR
  5424.     AH = 25h
  5425.     AL = interrupt number
  5426.     DS:DX = new vector to be used for specified interrupt
  5427. ---------------------------------------------
  5428. INT 21 - DOS - CREATE PSP
  5429.     AH = 26h
  5430.     DX = segment number at which to set up PSP
  5431. Return: current PSP is copied to specified segment
  5432. Note:    new PSP is updated with memory size information; INTs 22h, 23h, 24h
  5433.     taken from interrupt vector table
  5434.  
  5435. Format of PSP:
  5436. Offset    Size    Description
  5437.  00h  2 BYTEs    program exit point
  5438.  02h      WORD    memory size in paragraphs
  5439.  04h    BYTE    unused
  5440.  05h  5 BYTEs    CP/M entry point
  5441.  0Ah    DWORD    terminate address (old INT 22h)
  5442.  0Eh    DWORD    break address (old INT 23h)
  5443.  12h    DWORD    critical error handler (old INT 24h)
  5444.  16h    WORD    parent PSP segment
  5445.  18h 20 BYTEs    DOS 2+ open file table, FFh = unused
  5446.  2Ch    WORD    DOS 2+ environment segment
  5447.  2Eh    DWORD    DOS 2+ process's SS:SP on entry to last INT 21 call
  5448.  32h    WORD    DOS 3+ max open files
  5449.  34h    DWORD    DOS 3+ open file table address
  5450.  38h    DWORD    DOS 3+ ??? (set to FFFFFFFFh in DOS 3.1 and 3.3)
  5451.  3Ch 20 BYTEs    unused by DOS versions <= 3.3
  5452.  50h  3 BYTEs    DOS function dispatcher (FAR routine)--CDh 21h CBh
  5453.  53h  9 BYTEs    unused
  5454.  5Ch 16 BYTEs    FCB #1 (see AH=0Fh), filled in from first commandline argument
  5455.         (when opened, overwrites following FCB)
  5456.  6Ch 20 BYTEs    FCB #2 (see AH=0Fh), filled in from second commandline argument
  5457.         (when opened, overwrites part of command tail)
  5458.  80h 128 BYTEs    command tail / default DTA buffer
  5459.         command tail is BYTE for length of tail, N BYTEs for the tail,
  5460.         followed by a BYTE containing 0Dh
  5461. ---------------------------------------------
  5462. INT 21 - DOS - RANDOM BLOCK READ
  5463.     AH = 27h
  5464.     DS:DX -> FCB (see AH=0Fh)
  5465.     CX = number of records to be read
  5466. Return: AL = status
  5467.         00h successful read
  5468.         01h end of file
  5469.         02h data transfer area too small
  5470.         03h partial record, EOF
  5471. ---------------------------------------------
  5472. INT 21 - DOS - RANDOM BLOCK WRITE
  5473.     AH = 28h
  5474.     DS:DX -> FCB (see AH=0Fh)
  5475.     CX = number of records to be written
  5476.          if zero, truncate file to current random file position
  5477. Return: AL = status
  5478.         00h successful write
  5479.         01h disk full
  5480.         02h data transfer area too small
  5481. ---------------------------------------------
  5482. INT 21 - DOS - PARSE FILENAME
  5483.     AH = 29h
  5484.     DS:SI -> string to parse
  5485.     ES:DI -> buffer to fill with unopened FCB (see AH=0Fh)
  5486.     AL = bit mask to control parsing
  5487.         0 = 0: parsing stops if file separator found
  5488.         1: leading separators ignored
  5489.         1 = 0: drive number in FCB set to default drive if not present
  5490.            in string
  5491.         1: drive number in FCB not changed
  5492.         2 = 0: filename in FCB set to blanks if no filename in string
  5493.         1: filename in FCB not changed if string does not contain
  5494.            a filename
  5495.         3 = 0: extension in FCB set to blanks if no extension in string
  5496.         1: extension left unchanged
  5497. Return: AL = 00h no wildcards in name or extension
  5498.          01h wildcards appeared
  5499.          FFh drive specifier invalid
  5500.     DS:SI -> first byte after parsed string
  5501.     ES:DI buffer filled with unopened FCB
  5502. ---------------------------------------------
  5503. INT 21 - DOS - GET CURRENT DATE
  5504.     AH = 2Ah
  5505. Return: DL = day
  5506.     DH = month
  5507.     CX = year
  5508.     AL = day of the week (0=Sunday, 1=Monday, etc.)
  5509. ---------------------------------------------
  5510. INT 21 - DOS - SET CURRENT DATE
  5511.     AH = 2Bh
  5512.     DL = day
  5513.     DH = month
  5514.     CX = year
  5515. Return: AL = 00h if no error
  5516.        = FFh if bad value sent to routine
  5517. Note: DOS 3.3+ also sets CMOS clock
  5518. ---------------------------------------------
  5519. INT 21 - DESQview - INSTALLATION CHECK
  5520.     AH = 2Bh
  5521.     AL = subfunction (DV v2.00+)
  5522.         01h get version
  5523.         Return: BX = version (BH = major, BL = minor)
  5524.         Note: early copies of v2.00 return 0002h
  5525.         02h get shadow buffer info, and start shadowing
  5526.         Return: BH = rows in shadow buffer
  5527.             BL = columns in shadow buffer
  5528.             DX = segment of shadow buffer
  5529.         04h get shadow buffer info
  5530.         Return: BH = rows in shadow buffer
  5531.             BL = columns in shadow buffer
  5532.             DX = segment of shadow buffer
  5533.         05h stop shadowing
  5534.     CX = 4445h ('DE')
  5535.     DX = 5351h ('SQ')
  5536. Return: AL = FFh if DESQview not installed
  5537. Note:    in DESQview v1.x, there were no subfunctions; this call only identified
  5538.     whether or not DESQview was loaded
  5539. ---------------------------------------------
  5540. INT 21 - PC Tools v5.1 PC-CACHE - INSTALLATION CHECK
  5541.     AH = 2Bh
  5542.     CX = 4358h ('CX')
  5543. Return: AL = FFh if PC-CACHE not installed
  5544.     AL = 00h if installed
  5545.         CX = 6378h
  5546.         BX = ???
  5547.         DX = ???
  5548. ---------------------------------------------
  5549. INT 21 - DOS - GET CURRENT TIME
  5550.     AH = 2Ch
  5551. Return: CH = hours
  5552.     CL = minutes
  5553.     DH = seconds
  5554.     DL = hundredths of seconds
  5555. Note: time is updated approximately every 5/100 second
  5556. ---------------------------------------------
  5557. INT 21 - DOS - SET CURRENT TIME
  5558.     AH = 2Dh
  5559.     CH = hours
  5560.     CL = minutes
  5561.     DH = seconds
  5562.     DL = hundredths of seconds
  5563. Return: AL = 00h if no error
  5564.        = FFh if bad value sent to routine
  5565. Note: DOS 3.3+ also sets CMOS clock
  5566. ---------------------------------------------
  5567. INT 21 - DOS - SET VERIFY FLAG
  5568.     AH = 2Eh
  5569.     DL = 00h
  5570.     AL = 01h VERIFY on
  5571.          00h VERIFY off
  5572. ---------------------------------------------
  5573. INT 21 - DOS 2+ - GET DISK TRANSFER AREA ADDRESS
  5574.     AH = 2Fh
  5575. Return: ES:BX -> DTA
  5576. ---------------------------------------------
  5577. INT 21 - DOS 2+ - GET DOS VERSION
  5578.     AH = 30h
  5579. Return: AL = Major Version number (0 for DOS 1.x)
  5580.     AH = Minor Version number
  5581.     BH = OEM number
  5582.         00h IBM
  5583.         16h DEC
  5584.     BL:CX = 24-bit user number
  5585. ---------------------------------------------
  5586. INT 21 - DOS 2+ - TERMINATE BUT STAY RESIDENT
  5587.     AH = 31h
  5588.     AL = exit code
  5589.     DX = program size, in paragraphs
  5590. ---------------------------------------------
  5591. INT 21 - DOS 2+ internal - GET DRIVE PARAMETER BLOCK
  5592.     AH = 32h
  5593.     DL = drive number
  5594.         0 = default, 1 = A, etc.
  5595. Return: AL = 0FFh if invalid drive number, else
  5596.     DS:BX -> drive parameter block
  5597.  
  5598. Format of DOS Drive Parameter Block:
  5599. Offset    Size    Description
  5600.  00h    BYTE    drive number (0 = A, etc.)
  5601.  01h    BYTE    unit number within device driver
  5602.  02h    WORD    number of bytes per sector
  5603.  04h    BYTE    largest sector number in cluster (one less than sect/clust)
  5604.  05h    BYTE    log base two of the cluster size
  5605.  06h    WORD    number of reserved (boot) sectors
  5606.  08h    BYTE    number of copies of the FAT
  5607.  09h    WORD    number of root directory entries
  5608.  0Bh    WORD    first data sector on medium
  5609.  0Dh    WORD    largest possible cluster number (one more than # data clust)
  5610. ---DOS 2.x---
  5611.  0Fh    BYTE    number of sectors in one FAT copy
  5612.  10h    WORD    first sector of root directory
  5613.  12h    DWORD    address of device driver for this drive
  5614.  16h    BYTE    media descriptor byte for medium
  5615.  17h    BYTE    FFh indicates block must be rebuilt
  5616.  18h    DWORD    address of next device block, offset = FFFFh indicates last
  5617.  1Ch    WORD    starting cluster of current directory (0 = root directory)
  5618.  1Eh 64 BYTEs    ASCIZ current directory path string
  5619. ---DOS 3.x---
  5620.  0Fh    BYTE    number of sectors in one FAT copy
  5621.  10h    WORD    first sector of root directory
  5622.  12h    DWORD    address of device driver for this drive
  5623.  16h    BYTE    media descriptor byte for medium
  5624.  17h    BYTE    FFh = block must be rebuilt, 00h indicates block accessed
  5625.  18h    DWORD    address of next device block, offset = FFFFh indicates last
  5626.  1Ch    WORD    cluster at which to start search for free space when writing
  5627.  1Eh    WORD    number of free clusters on drive, FFFFh = unknown
  5628. ---DOS 4.0---
  5629.  0Fh    WORD    number of sectors in one FAT copy
  5630.  11h    WORD    first sector of root directory
  5631.  13h    DWORD    address of device driver for this drive
  5632.  17h    BYTE    media descriptor byte for medium
  5633.  18h    BYTE    FFh = block must be rebuilt, 00h indicates block accessed
  5634.  19h    DWORD    address of next device block, offset = FFFFh indicates last
  5635.  1Dh    WORD    cluster at which to start search for free space when writing
  5636.  1Fh    WORD    number of free clusters on drive, FFFFh = unknown???
  5637. ---------------------------------------------
  5638. INT 21 - DOS 2+ - EXTENDED CONTROL-BREAK CHECKING
  5639.     AH = 33h
  5640.     AL = subfunction
  5641.         00h get state
  5642.         01h set state
  5643.             DL = 00h for OFF or 01h for ON
  5644.         02h (DOS 3.x internal) get and set state
  5645.         DL = 00h for OFF or 01h for ON
  5646.         Return: DL = old BREAK setting
  5647. Return: DL = current BREAK setting if AL = 00h
  5648.         00h BREAK=OFF
  5649.         01h BREAK=ON
  5650.     AL = FFh if error
  5651. Note: under DOS 3+, this function does not use any of the DOS-internal stacks
  5652.     and is thus fully reentrant
  5653. ---------------------------------------------
  5654. INT 21 - DOS 4.0 - GET BOOT DRIVE
  5655.     AX = 3305h
  5656. Return: DL = boot drive (1=A:,...)
  5657. ---------------------------------------------
  5658. INT 21 - DOS 2+ internal - RETURN CritSectFlag POINTER
  5659.     AH = 34h
  5660. Return: ES:BX -> 1-byte DOS "Critical Section Flag", also known as InDOS flag
  5661. Notes:    when the critical section flag is nonzero, code within DOS is being
  5662.     executed.  It is safe to enter DOS when both the critical section flag
  5663.     and the critical error flag are zero.
  5664.  
  5665.     The critical error flag is the byte after the critical section flag in
  5666.     DOS 2.x, and the byte BEFORE the critical section flag in DOS 3.x 
  5667.     (except COMPAQ DOS 3.0, where the critical error flag is located 1AAh
  5668.     bytes BEFORE the critical section flag)
  5669. ---------------------------------------------
  5670. INT 21 - DOS 2+ - GET INTERRUPT VECTOR
  5671.     AH = 35h
  5672.     AL = interrupt number
  5673. Return: ES:BX = value of interrupt vector
  5674. ---------------------------------------------
  5675. INT 21 - DOS 2+ - GET DISK SPACE
  5676.     AH = 36h
  5677.     DL = drive code (0 = default, 1 = A, 2 = B, etc.)
  5678. Return: AX = number of sectors per cluster
  5679.          or 0FFFFh if invalid drive
  5680.     BX = number of available clusters
  5681.     CX = bytes per sector
  5682.     DX = total clusters
  5683. Note: multiply AX * CX * BX for free space on disk
  5684.       multiply AX * CX * DX for total disk space
  5685. ---------------------------------------------
  5686. INT 21 - DOS 2+ internal - GET SWITCHAR
  5687.     AX = 3700h
  5688. Return: AL = FFh unsupported subfunction
  5689.     DL = current switch character
  5690. ---------------------------------------------
  5691. INT 21 - DOS 2+ internal - SET SWITCHAR
  5692.     AX = 3701h
  5693.     DL = new switch character
  5694. Return: AL = FFh unsupported subfunction
  5695. ---------------------------------------------
  5696. INT 21 - DOS 2.x only internal - AVAILDEV
  5697.     AH = 37h
  5698.     AL = subfunction
  5699.        02h read device availability (as set by AL=03h)
  5700.         Return: DL = device availability
  5701.        03h set device availability, where:
  5702.         DL = 00h means \DEV\ must preceed device names
  5703.         DL <> 00h means \DEV\ need not preceed device names
  5704. Return: AL = FFh if invalid subfunction
  5705. ---------------------------------------------
  5706. INT 21 - DOS 2+ - GET COUNTRY-DEPENDENT INFORMATION
  5707.     AH = 38h
  5708. --DOS 2.x--
  5709.     AL = 00h get current-country info
  5710.     DS:DX -> buffer for returned info (see below)
  5711. Return: BX = country code
  5712.     buffer at DS:DX filled
  5713. --DOS 3+--
  5714.     AL = 00h for current country
  5715.     AL = 01h thru 0FEh for specific country with code <255
  5716.     AL = 0FFh for specific country with code >= 255
  5717.        BX = 16-bit country code
  5718.     DS:DX -> buffer for returned info (see below)
  5719. Return:    CF set on error
  5720.         AX = error code (02h)
  5721.     CF clear if successful
  5722.         BX = country code
  5723.         DS:DX buffer filled
  5724.  
  5725. Format of DOS 2.x country info:
  5726. Offset    Size    Description
  5727.  00h    WORD    date format  0 = USA    mm dd yy
  5728.                  1 = Europe dd mm yy
  5729.                  2 = Japan    yy mm dd
  5730.  02h    BYTE    currency symbol
  5731.  03h    BYTE    00h
  5732.  04h    BYTE    thousands separator char
  5733.  05h    BYTE    00h
  5734.  06h    BYTE    decimal separator char
  5735.  07h    BYTE    00h
  5736.  08h 24 BYTEs    reserved
  5737.  
  5738. Format of DOS 3+ country info:
  5739. Offset    Size    Description
  5740.  00h    WORD    date format (see above)
  5741.  02h  5 BYTEs    ASCIZ currency symbol string
  5742.  07h    BYTE    thousands separator char
  5743.  08h    BYTE    00h
  5744.  09h    BYTE    decimal separator char
  5745.  0Ah    BYTE    00h
  5746.  0Bh    BYTE    date separator char
  5747.  0Ch    BYTE    00h
  5748.  0Dh    BYTE    time separator char
  5749.  0Eh    BYTE    00h
  5750.  0Fh    BYTE    currency format
  5751.         bit 2 = set if currency symbol replaces decimal pt
  5752.         bit 1 = number of spaces between value and curr sym
  5753.         bit 0 = 0 if currency symbol precedes value
  5754.             1 if currency symbol follows value
  5755.  10h    BYTE    number of digits after decimal in currency
  5756.  11h    BYTE    time format
  5757.         bit 0 = 0 if 12-hour clock
  5758.             1 if 24-hour clock
  5759.  12h    DWORD    address of case map routine (FAR CALL, AL = char to map)
  5760.  16h    BYTE    data-list separator char
  5761.  17h    BYTE    00h
  5762.  18h 10 BYTEs    reserved
  5763. ---------------------------------------------
  5764. INT 21 - DOS 3+ - SET COUNTRY CODE
  5765.     AH = 38h
  5766.     AL = 01h thru 0FEh for specific country with code <255
  5767.     AL = FFh for specific country with code >= 255
  5768.        BX = 16-bit country code
  5769.     DX = FFFFh
  5770. Return: CF set on error
  5771.         AX = error code (see AH=59h)
  5772.     CF clear if successful
  5773. ---------------------------------------------
  5774. INT 21 - DOS 2+ - CREATE A SUBDIRECTORY (MKDIR)
  5775.     AH = 39h
  5776.     DS:DX -> ASCIZ pathname
  5777. Return: CF set on error
  5778.         AX = error code (03h,05h) (see AH=59h)
  5779. ---------------------------------------------
  5780. INT 21 - DOS 2+ - REMOVE A DIRECTORY ENTRY (RMDIR)
  5781.     AH = 3Ah
  5782.     DS:DX -> ASCIZ pathname
  5783. Return: CF set on error
  5784.         AX = error code (03h,05h,06h,10h) (see AH=59h)
  5785. ---------------------------------------------
  5786. INT 21 - DOS 2+ - CHANGE THE CURRENT DIRECTORY (CHDIR)
  5787.     AH = 3Bh
  5788.     DS:DX -> ASCIZ directory name
  5789. Return: CF set on error
  5790.         AX = error code (03h) (see AH=59h)
  5791. ---------------------------------------------
  5792. INT 21 - DOS 2+ - CREATE A FILE WITH HANDLE (CREAT)
  5793.     AH = 3Ch
  5794.     CX = attributes for file
  5795.         bit 0: read-only
  5796.         1: hidden
  5797.         2: system
  5798.         3: volume label
  5799.         4: reserved, must be zero (directory)
  5800.         5: archive bit
  5801.         7: if set, file is shareable under Novell NetWare
  5802.     DS:DX -> ASCIZ filename
  5803. Return: CF set on error
  5804.         AX = error code (03h,04h,05h) (see AH=59h)
  5805.     CF clear if successful
  5806.         AX = file handle
  5807. ---------------------------------------------
  5808. INT 21 - DOS 2+ - OPEN DISK FILE WITH HANDLE
  5809.     AH = 3Dh
  5810.     AL = access mode
  5811.         00h read only
  5812.         01h write only
  5813.         02h read/write
  5814.     AL bits 7-3 = file-sharing modes (DOS 3+)
  5815.         bit 7    = inheritance flag, set for no inheritance
  5816.         bits 4-6 = sharing mode
  5817.               000 compatibility mode
  5818.               001 exclusive (deny all)
  5819.               010 write access denied (deny write)
  5820.               011 read access denied (deny read)
  5821.               100 full access permitted (deny none)
  5822.         bit 3    = reserved, should be zero
  5823.     DS:DX -> ASCIZ filename
  5824. Return: CF set on error
  5825.         AX = error code (01h,02h,03h,04h,05h,0Ch) (see AH=59h)
  5826.     CF clear if successful
  5827.         AX = file handle
  5828. ---------------------------------------------
  5829. INT 21 - DOS 2+ - CLOSE A FILE WITH HANDLE
  5830.     AH = 3Eh
  5831.     BX = file handle
  5832. Return: CF set on error
  5833.         AX = error code (06h) (see AH=59h)
  5834. ---------------------------------------------
  5835. INT 21 - DOS 2+ - READ FROM FILE WITH HANDLE
  5836.     AH = 3Fh
  5837.     BX = file handle
  5838.     CX = number of bytes to read
  5839.     DS:DX -> buffer
  5840. Return: CF set on error
  5841.         AX = error code (05h,06h) (see AH=59h)
  5842.     CF clear if successful
  5843.         AX = number of bytes read (0 if at EOF before call)
  5844. ---------------------------------------------
  5845. INT 21 - DOS 2+ - WRITE TO FILE WITH HANDLE
  5846.     AH = 40h
  5847.     BX = file handle
  5848.     CX = number of bytes to write
  5849.     DS:DX -> buffer
  5850. Return: CF set on error
  5851.         AX = error code (05h,06h) (see AH=59h)
  5852.     CF clear if successful
  5853.         AX = number of bytes actually written
  5854. Note: if CX is zero, no data is written, and the file is truncated or extended
  5855.       to the current position
  5856. ---------------------------------------------
  5857. INT 21 - DOS 2+ - DELETE A FILE (UNLINK)
  5858.     AH = 41h
  5859.     DS:DX -> ASCIZ name of file to delete
  5860. Return: CF set on error
  5861.         AX = error code (02h,05h) (see AH=59h)
  5862. ---------------------------------------------
  5863. INT 21 - DOS 2+ - MOVE FILE READ/WRITE POINTER (LSEEK)
  5864.     AH = 42h
  5865.     AL = method
  5866.         00h offset from beginning of file
  5867.         01h offset from present location
  5868.         02h offset from end of file
  5869.     BX = file handle
  5870.     CX:DX = offset in bytes
  5871. Return: CF set on error
  5872.         AX = error code (01h,06h) (see AH=59h)
  5873.     CF clear if successful
  5874.         DX:AX = new offset
  5875. ---------------------------------------------
  5876. INT 21 - DOS 2+ - GET FILE ATTRIBUTES
  5877.     AX = 4300h
  5878.     DS:DX -> ASCIZ file name
  5879. Return: CF set on error
  5880.         AX = error code (01h,02h,03h,05h) (see AH=59h)
  5881.     CF clear if successful
  5882.         CX = file attributes (see AX=4301h)
  5883. ---------------------------------------------
  5884. INT 21 - DOS 2+ - PUT FILE ATTRIBUTES (CHMOD)
  5885.     AX = 4301h
  5886.     CX = file attribute bits
  5887.         bit 0 = read only
  5888.         1 = hidden file
  5889.         2 = system file
  5890.         3 = volume label
  5891.         4 = subdirectory
  5892.         5 = written since backup ("archive" bit)
  5893.         8 = shareable (Novell NetWare)
  5894.     DS:DX -> ASCIZ file name
  5895. Return: CF set on error
  5896.         AX = error code (01h,02h,03h,05h) (see AH=59h)
  5897. ---------------------------------------------
  5898. INT 21 - DOS 2+ - IOCTL - GET DEVICE INFORMATION
  5899.     AX = 4400h
  5900.     BX = file or device handle
  5901. Return: CF set on error
  5902.        AX = error code (see AH=59h)
  5903.     CF clear if successful
  5904.        DX = device info
  5905.        If bit 7 set: (character device)
  5906.            bit 0: console input device
  5907.            1: console output device
  5908.            2: NUL device
  5909.            3: CLOCK$ device
  5910.            4: device is special
  5911.            5: binary (raw) mode
  5912.            6: Not EOF
  5913.           12: network device (DOS 3+)
  5914.           14: can process IOCTL control strings (see AL = 02h-05h)
  5915.        If bit 7 clear: (file)
  5916.            bits 0-5 are block device number
  5917.            6: file has not been written
  5918.           12: network device (DOS 3+)
  5919.           14: ??? (DOS 3+)
  5920.           15: file is remote (DOS 3+)
  5921. ---------------------------------------------
  5922. INT 21 - DOS 2+ - IOCTL - SET DEVICE INFORMATION
  5923.     AX = 4401h
  5924.     BX = device handle
  5925.     DH = 0
  5926.     DL = device information to set (bits 0-7 from function 0)
  5927. Return: CF set on error
  5928.         AX = error code (see AH=59h)
  5929. ---------------------------------------------
  5930. INT 21 - DOS 2+ - IOCTL - READ CHARACTER DEVICE CONTROL STRING
  5931.     AX = 4402h
  5932.     BX = device handle
  5933.     CX = number of bytes to read
  5934.     DS:DX -> buffer
  5935. Return: CF set on error
  5936.         AX = error code (see AH=59h)
  5937.     CF clear if successful
  5938.         AX = number of bytes read
  5939. ---------------------------------------------
  5940. INT 21 - DOS 2+ - IOCTL - WRITE CHARACTER DEVICE CONTROL STRING
  5941.     AX = 4403h
  5942.     BX = device handle
  5943.     CX = number of bytes to write
  5944.     DS:DX -> buffer
  5945. Return: CF set on error
  5946.         AX = error code (see AH=59h)
  5947.     CF clear if successful
  5948.         AX = number of bytes written
  5949. ---------------------------------------------
  5950. INT 21 - DOS 2+ - IOCTL - READ BLOCK DEVICE CONTROL STRING
  5951.     AX = 4404h
  5952.     BL = drive number (0=default)
  5953.     CX = number of bytes to read
  5954.     DS:DX -> buffer
  5955. Return: CF set on error
  5956.         AX = error code (see AH=59h)
  5957.     CF clear if successful
  5958.         AX = number of bytes read
  5959. ---------------------------------------------
  5960. INT 21 - DOS 2+ - IOCTL - WRITE BLOCK DEVICE CONTROL STRING
  5961.     AX = 4405h
  5962.     BL = drive number (0=default)
  5963.     CX = number of bytes to write
  5964.     DS:DX -> buffer
  5965. Return: CF set on error
  5966.         AX = error code (see AH=59h)
  5967.     CF clear if successful
  5968.         AX = number of bytes written
  5969. ---------------------------------------------
  5970. INT 21 - DOS 2+ - IOCTL - GET INPUT STATUS
  5971.     AX = 4406h
  5972.     BX = file or device handle
  5973. Return: AL = FFh device ready
  5974.          00h device not ready
  5975. ---------------------------------------------
  5976. INT 21 - DOS 2+ - IOCTL - GET OUTPUT STATUS
  5977.     AX = 4407h
  5978.     BX = file or device handle
  5979. Return: AL = FFh device ready
  5980.          00h device not ready
  5981. Note: for DOS 2.x, files are always ready for output
  5982. ---------------------------------------------
  5983. INT 21 - DOS 3+ - IOCTL - BLOCK DEVICE CHANGEABLE
  5984.     AX = 4408h
  5985.     BL = drive number (0=default)
  5986. Return: AX = 00h removable
  5987.          01h fixed
  5988.          0Fh invalid drive
  5989. ---------------------------------------------
  5990. INT 21 - DOS 3+ - IOCTL - BLOCK DEVICE LOCAL
  5991.     AX = 4409h
  5992.     BL = drive number (0=default)
  5993. Return: DX = attribute word, bit 12 set if device is remote
  5994. ---------------------------------------------
  5995. INT 21 - DOS 3+ - IOCTL - HANDLE LOCAL
  5996.     AX = 440Ah
  5997.     BX = file handle
  5998. Return: DX = attribute word, bit 15 set if file is remote
  5999. Note:    if file is remote, Novell Advanced NetWare 2.0 returns the number of
  6000.     the file server on which the handle is located in CX
  6001. ---------------------------------------------
  6002. INT 21 - DOS 3+ - IOCTL - SET SHARING RETRY COUNT
  6003.     AX = 440Bh
  6004.     CX = delay (default 1)
  6005.     DX = retry count (default 3)
  6006. Return: CF set on error
  6007.         AX = error code (see AH=59h)
  6008. ---------------------------------------------
  6009. INT 21 - DOS 3.2+ - IOCTL - GENERIC
  6010.     AX = 440Ch
  6011.     BX = device handle
  6012.     CH = category code
  6013.         00h unknown (DOS 3.3+)
  6014.         01h COMn: (DOS 3.3+)
  6015.         03h CON (DOS 3.3+)
  6016.         05h LPTn:
  6017.     CL = function
  6018.         45h set iteration count
  6019.         4Ah select code page
  6020.         4Ch start code-page preparation
  6021.         4Dh end code-page preparation
  6022.         5Fh set display information (DOS 4.0)
  6023.         65h get iteration count
  6024.         6Ah query selected code page
  6025.         6Bh query prepare list
  6026.         7Fh get display information (DOS 4.0)
  6027.     DS:DX -> parameter block (see below)
  6028. Return: CF set on error
  6029.         AX = error code (see AH=59h)
  6030.  
  6031. Format of parameter block for function 45h:
  6032. Offset    Size    Description
  6033.  00h    WORD    number of times output is attempted before driver assumes
  6034.         device is busy
  6035.  
  6036. Format of parameter block for functions 4Ah and 6Ah:
  6037. Offset    Size    Description
  6038.  00h    WORD    length of data
  6039.  02h    WORD    code page ID
  6040.  04h 2N BYTEs    DCBS (double byte character set) lead byte range
  6041.           start/end for each of N ranges (DOS 4.0)
  6042.     WORD    0000h  end of data (DOS 4.0)
  6043.  
  6044. Format of parameter block for function 4Dh:
  6045. Offset    Size    Description
  6046.  00h    WORD    length of data
  6047.  02h    WORD    code page ID
  6048.  
  6049. Format of parameter block for function 4Ch:
  6050. Offset    Size    Description
  6051.  00h    WORD    flags
  6052.  02h    WORD    length of remainder of parameter block
  6053.  04h    WORD    number of code pages following
  6054.  06h  N WORDs    code page 1,...,N
  6055.  
  6056. Format of parameter block for functions 5Fh and 7Fh:
  6057. Offset    Size    Description
  6058.  00h    BYTE    level (0 for DOS 4.0)
  6059.  01h    BYTE    reserved (0)
  6060.  02h    WORD    length of following data (14)
  6061.  04h    WORD    control flags
  6062.           bit 0 set for blink, clear for intensity
  6063.           bits 1 to 15 reserved
  6064.  06h    BYTE    mode type (1=text, 2=graphics)
  6065.  07h    BYTE    reserved (0)
  6066.  08h    WORD    colors
  6067.            0 = monochrome
  6068.            else N bits per pixel
  6069.  0Ah    WORD    pixel columns
  6070.  0Ch    WORD    pixel rows
  6071.  0Eh    WORD    character columns
  6072.  10h    WORD    character rows
  6073.  
  6074. Format of parameter block for function 6Bh:
  6075. Offset    Size    Description
  6076.  00h    WORD    length of following data
  6077.  02h    WORD    number of hardware code pages
  6078.  04h  N WORDs    hardware code pages 1,...,N
  6079.     WORD    number of prepared code pages
  6080.       N WORDs    prepared code pages 1,...,N
  6081. ---------------------------------------------
  6082. INT 21 - DOS 3.2+ - IOCTL - BLOCK DEVICE REQUEST
  6083.     AX = 440Dh
  6084.     BL = drive number (0=default)
  6085.     CH = category code
  6086.         08h disk drive
  6087.     CL = function
  6088.          40h set device parameters
  6089.         41h write logical device track
  6090.         42h format and verify logical device track
  6091.         47h set access flag (DOS 4.0)
  6092.         60h get device parameters
  6093.         61h read logical device track
  6094.         62h verify logical device track
  6095.         67h get access flag (DOS 4.0)
  6096.     DS:DX -> parameter block (see below)
  6097. Return: CF set on error
  6098.        AX = error code (see AH=59h)
  6099. Note: DOS 4.01 seems to ignore the high byte of the number of directory entries
  6100.     in the BPB for diskettes.
  6101.  
  6102. Format of parameter block for functions 40h, 60h:
  6103. Offset    Size    Description
  6104.  00h    BYTE    special functions
  6105.         bit 0 set if function to use current BPB, clear if Device BIOS
  6106.             Parameter Block field contains new default BPB
  6107.         bit 1 set if function to use track layout fields only
  6108.             must be clear if CL=60h
  6109.         bit 2 set if all sectors in track same size (should be set)
  6110.         bits 3-7 reserved
  6111.  01h    BYTE    device type
  6112.         00h  320K/360K disk
  6113.         01h  1.2M disk
  6114.         02h  720K disk
  6115.         03h  single-density 8-inch disk
  6116.         04h  double-density 8-inch disk
  6117.         05h  fixed disk
  6118.         06h  tape drive
  6119.         07h  1.44M disk
  6120.         08h  other type of block device
  6121.  02h    WORD    device attributes
  6122.         bit 0 set if nonremovable medium
  6123.         bit 1 set if door lock supported
  6124.         bits 2-15 reserved
  6125.  04h    WORD    number of cylinders
  6126.  06h    BYTE    media type
  6127.         00h 1.2M disk (default)
  6128.         01h 320K/360K disk
  6129.  07h 31 BYTEs    device BPB (see AH=53h)
  6130.  26h    WORD    number of sectors per track (start of track layout field)
  6131.  28h  N word pairs: number,size of each sector in track
  6132.  
  6133. Format of parameter block for functions 41h, 61h:
  6134. Offset    Size    Description
  6135.  00h    BYTE    reserved, must be zero
  6136.  01h    WORD    number of disk head
  6137.  03h    WORD    number of disk cylinder
  6138.  05h    WORD    number of first sector to read/write
  6139.  07h    WORD    number of sectors
  6140.  09h    DWORD    transfer address
  6141.  
  6142. Format of parameter block for functions 42h, 62h:
  6143. Offset    Size    Description
  6144.  00h    BYTE    reserved, must be zero (DOS <3.2)
  6145.           bit 0=0: format/verify track
  6146.             1: format status call (DOS 3.2+)
  6147.           bits 1-7 reserved, must be zero
  6148.         on return (DOS 4.0):
  6149.           bit 0: set if specified tracks, sectors/track supported
  6150.           bit 1: set if function not supported by BIOS
  6151.           bit 2: set if specified tracks, sectors/track not supported
  6152.           bit 3: set if no disk in drive
  6153.  01h    WORD    number of disk head
  6154.  03h    WORD    number of disk cylinder
  6155.  
  6156. Format of parameter block for functions 47h, 67h:
  6157. Offset    Size    Description
  6158.  00h    BYTE    special-function field (must be zero)
  6159.  01h    BYTE    disk-access flag, nonzero if access allowed by driver
  6160. ---------------------------------------------
  6161. INT 21 - DOS 3.2+ - IOCTL - GET LOGICAL DRIVE MAP
  6162.     AX = 440Eh
  6163.     BL = drive number (0=default)
  6164. Return: CF set on error
  6165.         AX = error code (see AH=59h)
  6166.     CF clear if successful
  6167.         AL = 00h block device has only one logical drive assigned
  6168.          1..26 the last letter used to reference the drive (1=A:,etc)
  6169. ---------------------------------------------
  6170. INT 21 - DOS 3.2+ - IOCTL - SET LOGICAL DRIVE MAP
  6171.     AX = 440Fh
  6172.     BL = physical drive number (0=default)
  6173. Return: CF set on error
  6174.         AX = error code (see AH=59h)
  6175. Note: maps logical drives to physical drives, similar to DOS's treatment of
  6176.     a single physical floppy drive as both A: and B:
  6177. ---------------------------------------------
  6178. INT 21 - DOS 2+ - CREATE DUPLICATE HANDLE (DUP)
  6179.     AH = 45h
  6180.     BX = file handle to duplicate
  6181. Return: CF set on error
  6182.         AX = error code (04h,06h) (see AH=59h)
  6183.     CF clear if successful
  6184.         AX = new file handle
  6185. ---------------------------------------------
  6186. INT 21 - DOS 2+ - FORCE DUPLICATE HANDLE (FORCDUP,DUP2)
  6187.     AH = 46h
  6188.     BX = existing file handle
  6189.     CX = new file handle
  6190. Return: CF set on error
  6191.         AX = error code (04h,06h) (see AH=59h)
  6192. Note: closes file with handle BX if it is still open
  6193. ---------------------------------------------
  6194. INT 21 - DOS 2+ - GET CURRENT DIRECTORY
  6195.     AH = 47h
  6196.     DL = drive (0=default, 1=A, etc.)
  6197.     DS:SI points to 64-byte buffer area
  6198. Return: CF set on error
  6199.         AX = error code (0Fh) (see AH=59h)
  6200. Note: the returned path does not include the initial backslash
  6201. ---------------------------------------------
  6202. INT 21 - DOS 2+ - ALLOCATE MEMORY
  6203.     AH = 48h
  6204.     BX = number of 16-byte paragraphs desired
  6205. Return: CF set on error
  6206.         AX = error code (07h,08h) (see AH=59h)
  6207.         BX = size of largest available block
  6208.     CF clear if successful
  6209.         AX = segment of allocated memory block
  6210. ---------------------------------------------
  6211. INT 21 - DOS 2+ - FREE MEMORY
  6212.     AH = 49h
  6213.     ES = segment address of area to be freed
  6214. Return: CF set on error
  6215.         AX = error code (07h,09h) (see AH=59h)
  6216. ---------------------------------------------
  6217. INT 21 - DOS 2+ - ADJUST MEMORY BLOCK SIZE (SETBLOCK)
  6218.     AH = 4Ah
  6219.     ES = segment address of block to change
  6220.     BX = new size in paragraphs
  6221. Return: CF set on error
  6222.         AX = error code (07h,08h,09h) (see AH=59h)
  6223.         BX = maximum size possible for the block
  6224. ---------------------------------------------
  6225. INT 21 - DOS 2+ - LOAD OR EXECUTE (EXEC)
  6226.     AH = 4Bh
  6227.     AL = subfunction
  6228.         00h load and execute program
  6229.         01h load but do not execute (internal)
  6230.         03h load overlay; do not create PSP
  6231.     DS:DX -> ASCIZ filename
  6232.     ES:BX -> parameter block (see below)
  6233. Return: CF set on error
  6234.         AX = error code (01h,02h,05h,08h,0Ah,0Bh) (see AH=59h)
  6235.     CF clear if successful
  6236.         if function 1 and DOS 3+ or DESQview, process ID set to new
  6237.         program's PSP; get with INT 21/AH=62h
  6238.         if function 1 and DOS 2.x, new program's initial stack and 
  6239.         entry point returned in registers
  6240. Note: DOS 2.x destroys all registers, including SS:SP
  6241.  
  6242. Format of EXEC parameter block for AL=00h:
  6243. Offset    Size    Description
  6244.  00h    WORD    segment of environment (0 = use current)
  6245.  02h    DWORD    pointer to command line
  6246.  06h    DWORD    pointer to first FCB (see AH=0Fh)
  6247.  0Ah    DWORD    pointer to second FCB (see AH=0Fh)
  6248.  
  6249. Format of EXEC parameter block for AL=01h:
  6250. Offset    Size    Description
  6251.  00h    WORD    segment of environment (0 = use current)
  6252.  02h    DWORD    pointer to command line
  6253.  06h    DWORD    pointer to first FCB (see AH=0Fh)
  6254.  0Ah    DWORD    pointer to second FCB (see AH=0Fh)
  6255.  0Eh    DWORD    (DOS 3+) will hold subprogram's initial SS:SP on return
  6256.  12h    DWORD    (DOS 3+) will hold entry point (CS:IP) on return
  6257.  
  6258. Format of EXEC parameter block for AL=03h:
  6259. Offset    Size    Description
  6260.  00h    WORD    segment load address
  6261.  02h    WORD    segment relocation factor
  6262.  
  6263. Format of .EXE file header:
  6264. Offset    Size  Description
  6265.  00h    WORD  4Dh, 5Ah signature (sometimes 5Ah, 4Dh)
  6266.  02h    WORD  image size remainder (program size mod 512)
  6267.  04h    WORD  file size in pages (program size div 512) 
  6268.  06h    WORD  number of relocation items
  6269.  08h    WORD  header size in paragraphs
  6270.  0Ah    WORD  minimum extra paragraphs needed
  6271.  0Ch    WORD  maximum extra paragraphs needed
  6272.  0Eh    WORD  stack segment
  6273.  10h    WORD  stack offset
  6274.  12h    WORD  word checksum of entire file
  6275.  14h    DWORD initial CS:IP
  6276.  18h    WORD  offset of relocation table 
  6277.  1Ah    WORD  overlay number
  6278. ---------------------------------------------
  6279. INT 21 - DOS 2+ - QUIT WITH EXIT CODE (EXIT)
  6280.     AH = 4Ch
  6281.     AL = exit code
  6282. Return: never returns
  6283. ---------------------------------------------
  6284. INT 21 - DOS 2+ - GET EXIT CODE OF SUBPROGRAM (WAIT)
  6285.     AH = 4Dh
  6286. Return: AL = exit code of subprogram (from AH=31h or AH=4Ch)
  6287.     AH = circumstance which caused termination
  6288.         00h Terminate/abort
  6289.         01h Control-C/Control-Break
  6290.         02h Hard error
  6291.         03h Terminate and stay resident
  6292. ---------------------------------------------
  6293. INT 21 - DOS 2+ - FIND FIRST ASCIZ (FIND FIRST)
  6294.     AH = 4Eh
  6295.     CX = search attributes
  6296.     DS:DX -> ASCIZ filename
  6297. Return: CF set on error
  6298.         AX = error code (02h,12h) (see AH=59h)
  6299.     CF clear if successful
  6300.         [DTA] = data block (see below)
  6301.  
  6302. Format of FindFirst data block:
  6303. Offset    Size    Description
  6304. ---PCDOS 3.10, MSDOS 3.2/3.3---
  6305.  00h    BYTE    drive letter
  6306.  01h 11 BYTEs    search template
  6307.  0Ch    BYTE    search attributes
  6308. ---DOS 2.x (and some DOS 3.x???)---
  6309.  00h    BYTE    search attributes
  6310.  01h    BYTE    drive letter
  6311.  02h 11 BYTEs    search template
  6312. ---DOS 2.x and most 3.x---
  6313.  0Dh    WORD    entry count within directory
  6314.  0Fh  4 BYTEs    reserved
  6315.  13h    WORD    cluster number of start of parent directory
  6316. ---MSDOS 3.2/3.3---
  6317.  0Dh    WORD    entry count within directory
  6318.  0Fh    WORD    cluster number of start of parent directory
  6319.  11h  4 BYTEs    reserved
  6320. ---all versions, documented fields---
  6321.  15h    BYTE    attribute of file found
  6322.  16h    WORD    file time
  6323.             bits 11-15: hour
  6324.             bits 5-10:    minute
  6325.             bits 0-4:    seconds/2
  6326.  18h    WORD    file date
  6327.             bits 9-15:    year-1980
  6328.             bits 5-8:    month
  6329.             bits 0-4:    day
  6330.  1Ah    DWORD    file size
  6331.  1Eh 13 BYTEs    ASCIZ filename+extension
  6332. ---------------------------------------------
  6333. INT 21 - DOS 2+ - FIND NEXT ASCIZ (FIND NEXT)
  6334.     AH = 4Fh
  6335.     [DTA] = data block from last AH = 4Eh/4Fh call
  6336. Return: CF set on error
  6337.         AX = error code (12h) (see AH=59h)
  6338.     CF clear if successful
  6339.         [DTA] = data block (see AH=4Eh)
  6340. ---------------------------------------------
  6341. INT 21 - DOS 2+ internal - SET PSP SEGMENT
  6342.     AH = 50h
  6343.     BX = segment address of new PSP (see AH=26h)
  6344. Notes: under DOS 2.x, this function cannot be invoked inside an INT 28h
  6345.     handler without setting the Critical Error flag
  6346.        under DOS 3+, this function does not use any of the DOS-internal stacks
  6347.     and is thus fully reentrant
  6348. ---------------------------------------------
  6349. INT 21 - DOS 2+ internal - GET PSP SEGMENT
  6350.     AH = 51h
  6351. Return: BX = current PSP segment (see AH=26h)
  6352. Notes: under DOS 2.x, this function cannot be invoked inside an INT 28h
  6353.     handler without setting the Critical Error flag
  6354.        under DOS 3+, this function does not use any of the DOS-internal stacks
  6355.     and is thus fully reentrant
  6356. ---------------------------------------------
  6357. INT 21 - DOS 2+ internal - GET LIST OF LISTS
  6358.     AH = 52h
  6359. Return: ES:BX points to DOS list of lists
  6360. Note: not supported in OS/2 compatibility box
  6361.  
  6362. Format of List of Lists:
  6363. Offset    Size    Description
  6364.  -12    WORD    (DOS 3.1-3.3) sharing retry count (see AX=440Bh)
  6365.  -10    WORD    (DOS 3.1-3.3) sharing retry delay (see AX=440Bh)
  6366.  -8    DWORD    (DOS 3.x) pointer to current disk buffer
  6367.  -4    WORD    (DOS 3.x) ???  (default 0000h)
  6368.  -2    WORD    segment of first memory control block
  6369.  00h    DWORD    pointer to first DOS Device Control Block (see AH=32h)
  6370.  04h    DWORD    pointer to list of DOS file tables (see below)
  6371.  08h    DWORD    pointer to CLOCK$ device driver, resident or installable
  6372.  0Ch    DWORD    pointer to actual CON device driver, resident or installable
  6373. ---DOS 2.x---
  6374.  10h    BYTE    number of logical drives in system
  6375.  11h    WORD    maximum bytes/block of any block device
  6376.  13h    DWORD    pointer to first disk buffer (see below)
  6377.  17h    Beginning (not a pointer--the real beginning!) of NUL device driver.
  6378.     This is the first device on DOS's linked list of device drivers.
  6379.     (see below for format)
  6380. ---DOS 3.x---
  6381.  10h    WORD    maximum bytes/block of any block device
  6382.  12h    DWORD    pointer to first disk buffer (see below)
  6383.  16h    DWORD    pointer to array of drive info (see below)
  6384.  1Ah    DWORD    pointer to FCB table (if CONFIG.SYS contains FCBS=)
  6385.  1Eh    WORD    size of FCB table
  6386.  20h    BYTE    number of block devices
  6387.  21h    BYTE    value of LASTDRIVE command in CONFIG.SYS (default 5)
  6388.  22h 18 BYTEs    actual NUL device driver header (not a pointer!)
  6389.         This is the first device on DOS's linked list of device 
  6390.         drivers. (see below for format)
  6391.  34h    BYTE    number of JOIN'ed drives
  6392. ---DOS 3.1-3.3---
  6393.  35h    BYTE    ??? 90h (probably padding from "EVEN" assembler directive)
  6394.  36h    DWORD    SHARE.EXE hook: pointer to FAR routine for ???
  6395.  3Ah    DWORD    SHARE.EXE hook: pointer to FAR routine for ???
  6396.  3Eh    DWORD    SHARE.EXE hook -> FAR routine called on closing file???
  6397.  42h    DWORD    SHARE.EXE hook: pointer to ??? (called by AX=5D03h)
  6398.  46h    DWORD    SHARE.EXE hook: pointer to ??? (called by AX=5D04h)
  6399.  4Ah    DWORD    SHARE.EXE hook: pointer to ??? (called by AX=5D02h)
  6400.  4Eh    DWORD    SHARE.EXE hook -> FAR routine to lock region of file
  6401.         call with BX = file handle
  6402.               CX:DX = starting offset
  6403.               SI:AX = size
  6404.         Return: CF set on error
  6405.                 AL = DOS error code (see AH=59h)
  6406.         Note: only called if file is marked as remote
  6407.  52h    DWORD    SHARE.EXE hook -> FAR routine to unlock region of file
  6408.         call with BX = file handle
  6409.               CX:DX = starting offset
  6410.               SI:AX = size
  6411.         Return: CF set on error
  6412.                 AL = DOS error code (see AH=59h)
  6413.         Note: only called if file is marked as remote
  6414.  56h    DWORD    SHARE.EXE hook -> FAR routine to check if file region is locked
  6415.         call with ES:DI -> system file table entry for file
  6416.             CX = length of region from current position in file
  6417.         Return: CF set if any portion of region locked
  6418.                 AX = 0021h
  6419.  5Ah    DWORD    SHARE.EXE hook: pointer to ??? (called by AX=5D05h)
  6420.         Return: CF set on error or not loaded
  6421.             CF clear if successful
  6422.                 ES:DI -> ???
  6423.                 CX = ???
  6424.                 DX = ???
  6425.  5Eh    DWORD    SHARE.EXE hook: pointer to FAR routine for opening FCB???
  6426.         call with ES:DI -> unopened FCB
  6427.               DS:SI -> system file table entry
  6428.         Return: BL = C0h???
  6429.         Note: calls following fields from FCB to SFT:
  6430.                starting cluster of file       1Ah     0Bh
  6431.            sharing record offset      1Ch     33h
  6432.            file attribute          1Eh     04h
  6433.  62h    DWORD    SHARE.EXE hook: pointer to FAR routine for ???
  6434.         call with ES:DI -> system file table entry
  6435.               DS:SI -> FCB
  6436.         Return: CF set if SFT closed or sharing record offsets
  6437.                 mismatched
  6438.             CF clear if successful
  6439.                 BX = starting cluster number from FCB
  6440.  66h    DWORD    SHARE.EXE hook: pointer to FAR routine for ???
  6441.         Note: called during open/create of a file
  6442.  6Ah    DWORD    SHARE.EXE hook: pointer to FAR routine for ???
  6443.  6Eh    DWORD    SHARE.EXE hook -> FAR routine to update directory info in
  6444.                   related SFT entries
  6445.         call with ES:DI -> system file table entry for file (see below)
  6446.               AX = subfunction
  6447.                 00h: update time stamp (offset 0Dh) and date
  6448.                      stamp (offset 0Fh)
  6449.                 01h: update file size (offset 11h) and starting
  6450.                      cluster (offset 0Bh).  Under some
  6451.                      circumstances sets last read cluster
  6452.                      fields to start of file
  6453.                 02h: as function 01h, but last-read fields
  6454.                      always changed
  6455.                 03h: do both functions 00h and 02h
  6456.         Note: follows pointers at offset 2Bh in system file table
  6457. ---DOS 4.x---
  6458.  10h    WORD    maximum bytes/block of any block device
  6459.  12h    DWORD    pointer to disk buffer info (see below)
  6460.  16h    DWORD    pointer to array of drive info (see below)
  6461.  1Ah    DWORD    pointer to FCB table (if CONFIG.SYS contains FCBS=)
  6462.  1Eh    WORD    size of FCB table
  6463.  20h    BYTE    number of block devices
  6464.  21h    BYTE    value of LASTDRIVE command in CONFIG.SYS (default 5)
  6465.  22h 18 BYTEs    actual NUL device driver header (not a pointer!)
  6466.         This is the first device on DOS's linked list of device 
  6467.         drivers. (see below for format)
  6468.  34h    BYTE    number of JOIN'ed drives???
  6469.  
  6470. Format of memory control block:
  6471. Offset    Size    Description
  6472.  00h    BYTE    block type: 5Ah if last block in chain, otherwise 4Dh
  6473.  01h    WORD    PSP segment of owner, 0000h if free, 0008h if belongs to DOS
  6474.  03h    WORD    size of memory block in paragraphs
  6475.  05h  3 BYTEs    unused
  6476. ---DOS 3.x---
  6477.  08h  8 BYTEs    unused
  6478. ---DOS 4.x---
  6479.  08h  8 BYTEs    ASCII program name if PSP memory block, else garbage
  6480.         null-terminated if less than 8 characters
  6481.  
  6482. Format of DOS 2.x system file tables:
  6483. Offset    Size    Description
  6484.  00h    DWORD    pointer to next file table
  6485.  04h    WORD    number of files in this table
  6486.  06h  28h bytes per file
  6487.     Offset    Size    Description
  6488.      00h    BYTE    number of file handles referring to this file
  6489.      01h    BYTE    file open mode (see AH=3Dh)
  6490.      02h    BYTE    file attribute
  6491.      03h    BYTE    drive (0 = character device, 1 = A, 2 = B, etc)
  6492.      04h 11 BYTEs    filename in FCB format (no path,no period,blank-padded)
  6493.      0Fh    WORD    ???
  6494.      11h    WORD    ???
  6495.      13h    DWORD    file size???
  6496.      17h    WORD    file date in packed format (see AX=5700h)
  6497.      19h    WORD    file time in packed format (see AX=5700h)
  6498.      1Bh    BYTE    device attribute (see AX=4400h)
  6499.     ---character device---
  6500.      1Ch    DWORD    pointer to device driver
  6501.     ---block device---
  6502.      1Ch    WORD    starting cluster of file
  6503.      1Eh    WORD    relative cluster in file of last cluster read
  6504.     ------
  6505.      20h    WORD    absolute cluster number of current cluster
  6506.      22h    WORD    ???
  6507.      24h    DWORD    current file position???
  6508.  
  6509. Format of DOS 3+ system file tables and FCB tables:
  6510. Offset    Size    Description
  6511.  00h    DWORD    pointer to next file table
  6512.  04h    WORD    number of files in this table
  6513.  06h  35h bytes per file
  6514.     Offset    Size    Description
  6515.      00h    WORD    number of file handles referring to this file
  6516.      02h    WORD    file open mode (see AH=3Dh)
  6517.      04h    BYTE    file attribute
  6518.      05h    WORD    device info word (see AX=4400h)
  6519.      07h    DWORD    pointer to device driver header if character device
  6520.             else pointer to DOS Device Control Block (see AH=32h)
  6521.      0Bh    WORD    starting cluster of file
  6522.      0Dh    WORD    file time in packed format (see AX=5700h)
  6523.      0Fh    WORD    file date in packed format (see AX=5700h)
  6524.      11h    DWORD    file size
  6525.      15h    DWORD    current offset in file
  6526.      19h    WORD    relative cluster within file of last cluster read
  6527.      1Bh    WORD    absolute cluster number of last cluster read
  6528.      1Dh    WORD    number of sector containing directory entry
  6529.      1Fh    BYTE    number of dir entry within sector (byte offset/32)
  6530.      20h 11 BYTEs    filename in FCB format (no path/period, blank-padded)
  6531.      2Bh    DWORD    (SHARE.EXE) pointer to previous SFT sharing same file
  6532.      2Fh    WORD    (SHARE.EXE) ???
  6533.      31h    WORD    PSP segment of file's owner (see AH=26h)
  6534.      33h    WORD    offset within SHARE.EXE code segment of 
  6535.             sharing record (see below)  0000h = none
  6536.  
  6537. Format of sharing record:
  6538. Offset    Size    Description
  6539.  00h    BYTE    flag
  6540.         00h free block
  6541.         01h allocated block
  6542.  01h    WORD    size of block
  6543.  03h    BYTE    ???
  6544.  04h    WORD    offset in SHARE's DS of lock record (see below)
  6545.  06h    DWORD    pointer to start of system file table chain for file
  6546.  0Ah    WORD    ???
  6547.  0Ch    var    ASCIZ full pathname
  6548.  
  6549. Format of SHARE.EXE lock record:
  6550. Offset    Size    Description
  6551.  00h    WORD    offset in SHARE's DS of next lock table in list
  6552.  02h    DWORD    offset in file of start of locked region
  6553.  06h    DWORD    offset in file of end of locked region
  6554.  0Ah    DWORD    pointer to System File Table entry for this file
  6555.  0Eh    WORD    ??? 0 appears to mean 'in use'
  6556.  
  6557. Format of drive info table (array, 51h bytes [58h for DOS 4.x] per drive):
  6558. Offset    Size    Description
  6559.  00h 67 BYTEs    current path as ASCIZ, starting with 'x:\'
  6560.  43h    WORD    bit flags
  6561.         bit 15: network drive    \ invalid drive if neither bit set
  6562.         bit 14: physical drive    /
  6563.         bit 13: JOIN'ed, current path is actual path without JOIN
  6564.             drive letter in path may differ from logical drive name
  6565.         bit 12: SUBST'ed, current path is actual path without SUBST
  6566.             drive letter in path may differ from logical drive name
  6567.  45h    DWORD    pointer to DOS Disk Block for this drive
  6568.  49h    WORD    starting cluster of current dir
  6569.         0000h = root, FFFFh never accessed
  6570.  4Bh    WORD    ??? seems always to be FFFFh
  6571.  4Dh    WORD    ??? seems always to be FFFFh
  6572.  4Fh    WORD    Offset of '\' in current path field representing root directory 
  6573.         of logical drive (2 if not SUBST'ed or JOIN'ed, otherwise 
  6574.         number of bytes in SUBST/JOIN path)
  6575. ---DOS 4.x---
  6576.  51h  7 BYTEs    unknown, seems to always be zeros
  6577.  
  6578. Format of device driver header:
  6579. Offset    Size    Description
  6580.  00h    DWORD    pointer to next driver or FFFFh if last driver
  6581.  04h    WORD    device attributes
  6582.         Character device:
  6583.            bit 15  set
  6584.            bit 14  IOCTL supported
  6585.            bit 13  output until busy supported
  6586.            bit 12  reserved
  6587.            bit 11  OPEN/CLOSE/RemMedia calls supported
  6588.            bits 10-7 reserved
  6589.            bit 6  ??? (set by DOS 3.3 DISPLAY.SYS)
  6590.            bit 5  reserved
  6591.            bit 4  device is special (use INT 29 "fast console output")
  6592.            bit 3  device is CLOCK$
  6593.            bit 2  device is NUL
  6594.            bit 1  device is standard output
  6595.            bit 0  device is standard input
  6596.         Block device:
  6597.            bit 15  clear
  6598.            bit 14  IOCTL supported
  6599.            bit 13  non-IBM format
  6600.            bit 12  reserved
  6601.            bit 11  OPEN/CLOSE/RemMedia calls supported
  6602.            bit 10  reserved
  6603.            bit 9   ??? set by DOS 3.3 DRIVER.SYS for "new" drives
  6604.            bit 8   ??? set by DOS 3.3 DRIVER.SYS for "new" drives
  6605.            bits 7-2 reserved
  6606.            bit 1   driver supports 32-bit sector addressing
  6607.            bit 0   reserved
  6608.  06h    WORD    device strategy entry point
  6609.         call with ES:BX -> request header (see INT 2F/AX=1510h)
  6610.  08h    WORD    device interrupt entry point
  6611.  0Ah  8 BYTEs    blank-padded character device name
  6612.  12h    WORD    (CD-ROM driver) reserved, must be 0000h
  6613.  14h    BYTE    (CD-ROM driver) drive letter (must initially be 00h)
  6614.  15h    BYTE    (CD-ROM driver) number of units
  6615.  16h  6 BYTEs    (CD-ROM driver) signature 'MSCDnn' where 'nn' is version 
  6616.             (currently '00')
  6617.  
  6618. Format of DOS 2.x disk buffer:
  6619. Offset    Size    Description
  6620.  00h    DWORD    pointer to next disk buffer, offset = FFFFh if last
  6621.  04h    BYTE    drive (0=A, 1=B, etc), FFh if not in use
  6622.  05h  3 BYTEs    unused??? (seems always to be 00h 00h 01h)
  6623.  08h    WORD    logical sector number
  6624.  0Ah    BYTE    number of copies to write (1 for non-FAT sectors)
  6625.  0Bh    BYTE    sector offset between copies if multiple copies to be written
  6626.  0Ch    DWORD    pointer to DOS Device Control Block (see AH=32h)
  6627.  10h        buffered data
  6628.  
  6629. Format of DOS 3.x disk buffer:
  6630. Offset    Size    Description
  6631.  00h    DWORD    pointer to next disk buffer, offset = FFFFh if last
  6632.  04h    BYTE    drive (0=A,1=B, etc), FFh if not in use
  6633.  05h    BYTE    flags
  6634.         bit 7: ???
  6635.         bit 6: buffer dirty
  6636.         bit 5: buffer in use
  6637.         bit 4: ???
  6638.         bit 3: sector in data area
  6639.         bit 2: sector in a directory, either root or subdirectory
  6640.         bit 1: sector in FAT
  6641.         bit 0: boot sector??? (guess)
  6642.  06h    WORD    logical sector number
  6643.  08h    BYTE    number of copies to write (1 for non-FAT sectors)
  6644.  09h    BYTE    sector offset between copies if multiple copies to be written
  6645.  0Ah    DWORD    pointer to DOS Device Control Block (see AH=32h)
  6646.  0Eh    WORD    unused??? (almost always 0)
  6647.  10h        buffered data
  6648.  
  6649. Format of DOS 4.x disk buffer info:
  6650. Offset    Size    Description
  6651.  00h    DWORD    pointer to array of chain heads (see below)
  6652.  04h    WORD    number of disk buffer chains (referred to as NDBCH below)
  6653.  06h    DWORD    pointer to lookahead buffer, zero if not present
  6654.  0Ah    BYTE    number of lookahead sectors, else zero (the y in BUFFERS=x,y)
  6655.  0Bh    WORD    ??? seems always to be zero
  6656.  0Dh    WORD    EMS handle for buffers, zero if not in EMS
  6657.  0Fh    WORD    EMS physical page number used for buffers (usually 255)
  6658.  11h    WORD    ??? seems always to be 1
  6659.  13h    WORD    segment of EMS physical page frame
  6660.  15h    WORD    ??? seems always to be zero
  6661.  17h  4 WORDs    EMS partial page mapping information???
  6662.  
  6663. Format of DOS 4.x disk buffer chain head (array, one entry per chain):
  6664. Offset    Size    Description
  6665.  00h    WORD    EMS logical page number in which chain is resident, garbage if
  6666.         not using EMS
  6667.  02h    DWORD    pointer to least recently used buffer header.  All buffers on
  6668.         this chain are in the same segment.
  6669.  06h    WORD    ??? seems always to be zero
  6670. Note:    Buffered disk sectors are assigned to chain N where N is the sector's
  6671.     address modulo NDBCH,  0 <= N <= NDBCH-1.  Each chain resides 
  6672.     completely within one EMS page.  This structure is in main memory even
  6673.     if buffers are in EMS.
  6674.  
  6675. Format of DOS 4.x disk buffer:
  6676. Offset    Size    Description
  6677.  00h    WORD    forward ptr, offset only, to next least recently used buffer
  6678.  02h    WORD    backward ptr, offset only
  6679.  04h    BYTE    drive (0=A,1=B, etc), FFh if not in use
  6680.  05h    BYTE    flags
  6681.         bit 7: ???
  6682.         bit 6: buffer dirty???
  6683.         bit 5: buffer in use???
  6684.         bit 4: ???
  6685.         bit 3: sector in data area
  6686.         bit 2: sector in a directory, either root or subdirectory
  6687.         bit 1: sector in FAT
  6688.         bit 0: ???
  6689.  06h    DWORD    logical sector number
  6690.  0Ah    BYTE    number of copies to write
  6691.         for FAT sectors, same as number of FATs
  6692.         for data and directory sectors, usually 1
  6693.  0Bh    WORD    offset in sectors between copies to write for FAT sectors
  6694.  0Dh    DWORD    pointer to DOS Device Control Block (see AH=32h)
  6695.  11h  3 BYTEs    ??? zero or unset garbage
  6696.  14h        buffered data
  6697. Note:    All buffered sectors which have the same address modulo NDBCH are on
  6698.     the same doubly-linked circular chain.    The links consist of offset 
  6699.     addresses only, the segment being the same for all buffers in the
  6700.     chain.
  6701. ---------------------------------------------
  6702. INT 21 - DOS 2+ internal - TRANSLATE BIOS PARAMETER BLOCK
  6703.     AH = 53h
  6704.     DS:SI -> BPB (Bios Parameter Block)
  6705.     ES:BP -> buffer for DOS Disk Block
  6706. Note:    Translates BPB (see below) into a DOS Disk Block (see AH=32h).
  6707.  
  6708. Format of BPB:
  6709. Offset    Size    Description
  6710.  00h    WORD    bytes/sector. Get from DDB bytes 2-3.
  6711.  02h    BYTE    sectors/cluster. Get from (DDB byte 4) + 1
  6712.  03h    WORD    reserved sectors. Get from DDB bytes 6-7
  6713.  05h    BYTE    number of FATs. Get from DDB byte 8
  6714.  06h    WORD    number of root dir entries. Get from DDB bytes 09h-0Ah
  6715.  08h    WORD    total number of sectors. Get from:
  6716.           ((DDB bytes 0Dh-0Eh) - 1) * (sectors/cluster (BPB byte 2))
  6717.             + (DDB Bytes 0Bh-0Ch)
  6718.         for DOS 4.0, set to zero if partition >32M, then set DWORD
  6719.         at 15h to actual number of sectors
  6720.  0Ah    BYTE    media descriptor byte. Get from DDB byte 16h
  6721.  0Bh    WORD    number of sectors/FAT. Get from DDB byte 0Fh
  6722. ---DOS 3+---
  6723.  0Dh    WORD    number of sectors per track
  6724.  0Fh    WORD    number of heads
  6725.  11h    DWORD    number of hidden sectors
  6726.  15h 11 BYTEs    reserved    
  6727. ---DOS 4.0---
  6728.  15h    DWORD    total number of sectors if word at 08h contains zero
  6729. ---------------------------------------------
  6730. INT 21 - DOS 2+ - GET VERIFY FLAG
  6731.     AH = 54h
  6732. Return: AL = 00h if flag OFF
  6733.     AL = 01h if flag ON
  6734. ---------------------------------------------
  6735. INT 21 - DOS 2+ internal - CREATE PSP
  6736.     AH = 55h
  6737.     DX = segment number at which to set up PSP (see AH=26h)
  6738.     SI = value to place in memory size field at DX:[0002h]
  6739. Note: Like AH=26h but creates "child" PSP rather than copying existing one.
  6740. ---------------------------------------------
  6741. INT 21 - DOS 2+ - RENAME A FILE
  6742.     AH = 56h
  6743.     DS:DX -> ASCIZ old name
  6744.     ES:DI -> ASCIZ new name
  6745. Return: CF set on error
  6746.         AX = error code (02h,03h,05h,11h) (see AH=59h)
  6747. Note: allows move between directories on same logical volume
  6748.       (DOS 3+) allows renaming of directories
  6749. ---------------------------------------------
  6750. INT 21 - DOS 2+ - GET FILE'S DATE/TIME
  6751.     AX = 5700h
  6752.     BX = file handle
  6753. Return: CF set on error
  6754.         AX = error code (01h,06h) (see AH=59h)
  6755.     CF clear if successful
  6756.         CX = time of last write
  6757.         bits 11-15: hour
  6758.              5-10:  minute
  6759.              0-4:   seconds/2
  6760.         DX = date of last write
  6761.         bits 9-15:   year-1980
  6762.              5-8:    month
  6763.              0-4:    day
  6764. ---------------------------------------------
  6765. INT 21 - DOS 2+ - SET FILE'S DATE/TIME
  6766.     AX = 5701h
  6767.     BX = file handle
  6768.     CX = time to be set (see AX=5700h)
  6769.     DX = date to be set (see AX=5700h)
  6770. Return: CF set on error
  6771.         AX = error code (01h,06h) (see AH=59h)
  6772. ---------------------------------------------
  6773. INT 21 - DOS 4.0 - ???
  6774.     AX = 5702h
  6775.     ???
  6776. Return: ???
  6777. ---------------------------------------------
  6778. INT 21 - DOS 4.0 - ???
  6779.     AX = 5704h
  6780.     ???
  6781. Return: ???
  6782. ---------------------------------------------
  6783. INT 21 - DOS 3+ - GET/SET MEMORY ALLOCATION STRATEGY
  6784.     AH = 58h
  6785.     AL = function code
  6786.         00h get allocation strategy
  6787.         01h set allocation strategy
  6788.            BL = strategy code
  6789.            00h first fit (use first memory block large enough)
  6790.            01h best fit (use smallest memory block large enough)
  6791.            02h last fit (use high part of last usable memory block)
  6792. Return: CF set on error
  6793.         AX = error code (01h) (see AH=59h)
  6794.     CF clear if successful
  6795.         AX = strategy code
  6796. Note: the Set subfunction accepts any value in BL; 2 or greater means last fit.
  6797.       the Get subfunction returns the last value set, so programs should check
  6798.       whether the value is >= 2, not just equal to 2.
  6799. ---------------------------------------------
  6800. INT 21 - DOS 3+ - GET EXTENDED ERROR CODE
  6801.     AH = 59h
  6802.     BX = version code (0000h for DOS 3.x)
  6803. Return: AX = extended error code (see below)
  6804.     BH = class of error (see below)
  6805.     BL = suggested action (see below)
  6806.     CH = locus (where error occurred) (see below)
  6807.     CL, DX, SI, DI, BP, DS, and ES destroyed
  6808.  
  6809. Values for extended error code:
  6810.     01h function number invalid
  6811.     02h file not found
  6812.     03h path not found
  6813.     04h too many open files (no handles available)
  6814.     05h access denied
  6815.     06h invalid handle
  6816.     07h memory control block destroyed
  6817.     08h insufficient memory
  6818.     09h memory block address invalid
  6819.     0Ah environment invalid
  6820.     0Bh format invalid
  6821.     0Ch access code invalid
  6822.     0Dh data invalid
  6823.     0Fh invalid drive
  6824.     10h attempted to remove current directory
  6825.     11h not same device
  6826.     12h no more files
  6827.     13h disk write-protected
  6828.     14h unknown unit
  6829.     15h drive not ready
  6830.     16h unknown command
  6831.     17h data error (CRC)
  6832.     18h bad request structure length
  6833.     19h seek error
  6834.     1Ah unknwon media type (non-DOS disk)
  6835.     1Bh sector not found
  6836.     1Ch printer out of paper
  6837.     1Dh write fault
  6838.     1Eh read fault
  6839.     1Fh general failure
  6840.     20h sharing violation
  6841.     21h lock violation
  6842.     22h disk change invalid
  6843.         ES:DI -> ASCIZ volume label of required disk
  6844.     23h FCB unavailable
  6845.     24h sharing buffer overflow
  6846.     25h-31h reserved
  6847.     32h Network request not supported (DOS 3.1 + MS Networks)
  6848.     33h Remote computer not listening
  6849.     34h Duplicate name on network
  6850.     35h Network name not found
  6851.     36h Network busy
  6852.     37h Network device no longer exists
  6853.     38h Network BIOS command limit exceeded
  6854.     39h Network adapter hardware error
  6855.     3Ah Incorrect response from network
  6856.     3Bh Unexpected network error
  6857.     3Ch Incompatible remote adapter
  6858.     3Dh Print queue full
  6859.     3Eh Queue not full
  6860.     3Fh Not enough space to print file
  6861.     40h Network name was deleted
  6862.     41h Network: Access denied
  6863.     42h Network device type incorrect
  6864.     43h Network name not found
  6865.     44h Network name limit exceeded
  6866.     45h Network BIOS session limit exceeded
  6867.     46h Temporarily paused
  6868.     47h Network request not accepted
  6869.     48h Print/disk redirection paused (DOS 3.1 + MS Networks)
  6870.     49h-4Fh reserved
  6871.     50h file exists
  6872.     51h reserved
  6873.     52h cannot make directory
  6874.     53h fail on INT 24h
  6875.     54h (DOS 3.3+) too many redirections
  6876.     55h (DOS 3.3+) duplicate redirection
  6877.     56h (DOS 3.3+) invalid password
  6878.     57h (DOS 3.3+) invalid parameter
  6879.     58h (DOS 3.3+) network write fault
  6880. Values for Error Class:
  6881.     01h out of resource (storage space or I/O channels)
  6882.     02h temporary situation (file or record lock)
  6883.     03h authorization (denied access)
  6884.     04h internal (system software bug)
  6885.     05h hardware failure
  6886.     06h system failure (configuration file missing or incorrect)
  6887.     07h application program error
  6888.     08h not found
  6889.     09h bad format
  6890.     0Ah locked
  6891.     0Bh media error
  6892.     0Ch already exists
  6893.     0Dh unknown
  6894. Values for Suggested Action:
  6895.     01h retry
  6896.     02h delayed retry
  6897.     03h prompt user to reenter input
  6898.     04h abort after cleanup
  6899.     05h immediate abort
  6900.     06h ignore
  6901.     07h retry after user intervention
  6902. Values for Error Locus:
  6903.     01h unknown or not appropriate
  6904.     02h block device (disk error)
  6905.     03h network related
  6906.     04h serial device (timeout)
  6907.     05h memory related
  6908. ---------------------------------------------
  6909. INT 21 - DOS 3+ - CREATE UNIQUE FILE
  6910.     AH = 5Ah
  6911.     DS:DX -> ASCIZ directory path name ending with a '\' + 13 bytes to
  6912.          receive generated filename
  6913.     CX = file attributes (only bits 0,1,2,5 may be set)
  6914. Return: CF set on error
  6915.         AX = error code (03h,05h) (see AH=59h)
  6916.     CF clear if successful
  6917.         AX = file handle
  6918.     DS:DX -> path name
  6919. Note: The file created is not truly temporary.    It MUST be removed by the user.
  6920. ---------------------------------------------
  6921. INT 21 - DOS 3+ - CREATE NEW FILE
  6922.     AH = 5Bh
  6923.     DS:DX -> ASCIZ directory path name
  6924.     CX = file attribute
  6925. Return: CF set on error
  6926.         AX = error code (03h,04h,05h,50h) (see AH=59h)
  6927.     CF clear if successful
  6928.     DS:DX -> path name
  6929. Note: Unlike function 3Ch, function 5Bh will fail if the file already exists.
  6930. ---------------------------------------------
  6931. INT 21 - DOS 3+ - LOCK/UNLOCK FILE ACCESS
  6932.     AH = 5Ch
  6933.     AL = 00h lock
  6934.          01h unlock
  6935.     BX = file handle
  6936.     CX:DX = starting offset of region to lock
  6937.     SI:DI = size of region to lock
  6938. Return: CF set on error
  6939.         AX = error code (01h,06h,21h) (see AH=59h)
  6940. Note: error returned unless SHARE or network installed
  6941. ---------------------------------------------
  6942. INT 21 - DOS 3.1 internal - INDIRECT FUNCTION CALL
  6943.     AX = 5D00h
  6944.     DS:DX -> buffer containing register values (see AX=5D0Ah)
  6945.          for a call to INT 21h
  6946. Return: as appropriate for function being called
  6947. Notes:    does not check AH.  Out of range values will crash the system
  6948. ---------------------------------------------
  6949. INT 21 - DOS 3.1 internal - SYNC???
  6950.     AX = 5D01h
  6951.     DS:DX -> buffer (see AX=5D0Ah), only fields at offset 12h, 14h used
  6952.     ???
  6953. Return: ???
  6954. Note: does something to each disk file in the System File Table which has been
  6955.     written to; if remote file, calls INT 2F/AX=1107h
  6956.       seems to update the time stamp of all open files which have been written
  6957. ---------------------------------------------
  6958. INT 21 - DOS 3.1 internal - SHARE.EXE - ???
  6959.     AX = 5D02h
  6960.     DS:DX -> buffer (see AX=5D0Ah), only fields at offset 12h, 14h used
  6961.     ???
  6962. Return: ???
  6963. Note: error unless SHARE is loaded (calls [ListofLists+4Ah]) (see AH=52h)
  6964. ---------------------------------------------
  6965. INT 21 - DOS 3.1 internal - SHARE.EXE - ???
  6966.     AX = 5D03h
  6967.     DS:DX -> buffer (see AX=5D0Ah), only fields at offset 12h, 14h used
  6968.     ???
  6969. Return: ???
  6970. Note: error unless SHARE is loaded (calls [ListofLists+42h]) (see AH=52h)
  6971. ---------------------------------------------
  6972. INT 21 - DOS 3.1 internal - SHARE.EXE - ???
  6973.     AX = 5D04h
  6974.     DS:DX -> buffer (see AX=5D0Ah), only fields at offset 12h, 14h used
  6975.     ???
  6976. Return: ???
  6977. Note: error unless SHARE is loaded (calls [ListofLists+46h]) (see AH=52h)
  6978. ---------------------------------------------
  6979. INT 21 - DOS 3.1 internal - SHARE.EXE - ???
  6980.     AX = 5D05h
  6981.     DS:DX -> buffer (see AX=5D0Ah), only fields at offset 12h, 14h used
  6982.     ???
  6983. Return: ES:DI -> ???
  6984.     BX = ???
  6985.     CX = ???
  6986. Note: error unless SHARE is loaded (calls [ListOfLists+5Ah]) (see AH=52h)
  6987. ---------------------------------------------
  6988. INT 21 - DOS 3+ internal - GET ADDRESS OF CRITICAL ERROR FLAG
  6989.     AX = 5D06h
  6990.     DS:DX -> buffer (see AX=5D0Ah), only fields at offset 12h, 14h used
  6991. Return: DS:SI -> critical error flag
  6992.     BX = ???
  6993.     CX = ???
  6994. Notes:    this call does a lot of other work in addition to returning the    pointer
  6995.     setting CritErr flag allows use of functions 50h/51h from INT 28h under
  6996.     DOS 2.x by forcing use of correct stack
  6997. ---------------------------------------------
  6998. INT 21 - DOS 3+ internal - ???
  6999.     AH = 5Dh
  7000.     AL = subfunction
  7001.          07h: ???
  7002.          08h: ??? (used by COMMAND.COM)
  7003.          09h: ??? (used by COMMAND.COM)
  7004. Return: ???
  7005. Note: in DOS 3.10 and 3.30, these are identical, and call INT 2F/AX=1125h
  7006. ---------------------------------------------
  7007. INT 21 - DOS 3.1+ internal - SET EXTENDED ERROR INFORMATION
  7008.     AX = 5D0Ah
  7009.     DS:DX -> 11-word error information table
  7010.  
  7011. Format of error information table:
  7012. Offset    Size    Description
  7013.  00h    WORD    value that next call to function 59h will return in AX 
  7014.  02h    WORD    value that next call to function 59h will return in BX
  7015.  04h    WORD    CX
  7016.  06h    WORD    DX
  7017.  08h    WORD    SI
  7018.  0Ah    WORD    DI
  7019.  0Ch    WORD    DS
  7020.  0Eh    WORD    ES
  7021.  10h    WORD    reserved (0)
  7022.  12h    WORD    ??? (0 for DOS 3.1)
  7023.  14h    WORD    ??? (0 for DOS 3.1)
  7024. ---------------------------------------------
  7025. INT 21 - DOS 3.1 + Microsoft Networks - GET MACHINE NAME
  7026.     AX = 5E00h
  7027.     DS:DX -> buffer for ASCIZ name (16 bytes)
  7028. Return: CF set on error
  7029.         AX = error code (01h) (see AH=59h)
  7030.     CH = 00h if name not defined
  7031.       <> 00h defined
  7032.         CL = NETBIOS name number
  7033.         DS:DX -> ASCIZ machine name
  7034. ---------------------------------------------
  7035. INT 21 - DOS 3.1 + Microsoft Networks - SET MACHINE NAME
  7036.     AX = 5E01h
  7037.     CH = 00h undefine name
  7038.        <> 0  define name
  7039.     CL = name number
  7040.     DS:DX -> ASCIZ name
  7041. ---------------------------------------------
  7042. INT 21 - DOS 3.1 + Microsoft Networks - SET PRINTER SETUP
  7043.     AX = 5E02h
  7044.     BX = redirection list index
  7045.     CX = length of setup string (<= 64)
  7046.     DS:SI -> string buffer
  7047. Return: CF set on error
  7048.         AX = error code (01h) (see AH=59h)
  7049. ---------------------------------------------
  7050. INT 21 - DOS 3.1 + Microsoft Networks - GET PRINTER SETUP
  7051.     AX = 5E03h
  7052.     BX = redirection list index
  7053.     ES:DI -> string buffer
  7054. Return: CF set on error
  7055.         AX = error code (01h) (see AH=59h)
  7056.     CX = length of setup string (<= 64)
  7057. ---------------------------------------------
  7058. INT 21 - DOS 3.1 + Microsoft Networks - something to do with PRINTER SETUP???
  7059.     AX = 5E04h
  7060.     ???
  7061. Return: CF set on error
  7062. Note:    calls INT 2F/AX=111Fh with 5E04h on stack
  7063. ---------------------------------------------
  7064. INT 21 - DOS 3.1 + Microsoft Networks - something to do with PRINTER SETUP???
  7065.     AX = 5E05h
  7066.     ???
  7067. Return: CF set on error
  7068. Note:    calls INT 2F/AX=111Fh with 5E05h on stack
  7069. ---------------------------------------------
  7070. INT 21 - DOS 3.1 + Microsoft Networks - something to do with PRINTER SETUP???
  7071.     AX = 5E06h
  7072.     ???
  7073. Return: CF set on error
  7074. Note:    calls INT 2F/AX=111Fh with 5E06h on stack
  7075. ---------------------------------------------
  7076. INT 21 - DOS 3.1 + Microsoft Networks - GET REDIRECTION LIST ENTRY
  7077.     AX = 5F02h
  7078.     BX = redirection list index
  7079.     DS:SI -> 16 char local device name buffer
  7080.     ES:DI -> 128 char network name buffer
  7081. Return: CF set on error
  7082.         AX = error code (01h,12h) (see AH=59h)
  7083.     BH = device status flag (bit 0 = 0 if valid)
  7084.     BL = device type (03h if printer, 04h if drive)
  7085.     CX = stored parameter value (user data)
  7086. Note: DX and BP are destroyed by this call!
  7087. ---------------------------------------------
  7088. INT 21 - DOS 3.1 + Microsoft Networks - REDIRECT DEVICE
  7089.     AX = 5F03h
  7090.     BL = device type
  7091.         03 = printer device
  7092.         04 = file device
  7093.     CX = stored parameter value
  7094.     DS:SI -> ASCIZ source device name
  7095.     ES:DI -> destination ASCIZ network path + ASCIZ password
  7096. Return: CF set on error
  7097.         AX = error code (01h,03h,05h,08h) (see AH=59h)
  7098. ---------------------------------------------
  7099. INT 21 - DOS 3.1 + Microsoft Networks - CANCEL REDIRECTION
  7100.     AX = 5F04h
  7101.     DS:SI -> ASCIZ device name or network path
  7102. Return: CF set on error
  7103.         AX = error code (01h,0Fh) (see AH=59h)
  7104. ---------------------------------------------
  7105. INT 21 - DOS 3+ internal - RESOLVE PATH STRING TO FULLY QUALIFIED PATH STRING
  7106.     AH = 60h
  7107.     DS:SI -> ASCIZ relative path string
  7108.     ES:DI -> 80-byte buffer for ASCIZ fully qualified name
  7109. Return: CF set on error
  7110.         AX = error code 
  7111.         02h invalid source name
  7112.         03h invalid drive or malformed path
  7113.         others???
  7114.     CF clear if successful
  7115.         AX = ??? (0000h, 0040h, 004Eh, 0050h, 005Ch seen)
  7116.         buffer filled with qualified name of form D:\PATH\FILE.EXT
  7117. Note:    if path string is on a JOINed drive, the returned name is the one that
  7118.     would be needed if the drive were not JOINed; similarly for a SUBSTed
  7119.     drive letter.  Because of this, it is possible to get a qualified name
  7120.     that is not legal with the current combination of SUBSTs and JOINs
  7121. ---------------------------------------------
  7122. INT 21 - DOS 3+ internal - UNUSED
  7123.     AH = 61h
  7124. Return: AL = 00h
  7125. ---------------------------------------------
  7126. INT 21 - DOS 3+ - GET PSP ADDRESS
  7127.     AH = 62h
  7128. Return: BX = segment address of PSP
  7129. Note:    under DOS 3+, this function does not use any of the DOS-internal stacks
  7130.     and is thus fully reentrant
  7131. ---------------------------------------------
  7132. INT 21 - DOS 2.25 only - GET LEAD BYTE TABLE (2-BYTE CHARACTER SUPPORT)
  7133.     AH = 63h
  7134.     AL = subfunction
  7135.          00h get system lead byte table
  7136.         Return:    DS:SI -> lead byte table
  7137.          01h set/clear interim console flag (determine whether interim
  7138.             bytes are returned on some console functions)
  7139.         DL = 01h/00h to set/clear interim console flag
  7140.          02h get interim console flag
  7141.         Return:    DL = interim console flag
  7142. Return: CF set on error
  7143.         AX = error code (01h) (see AH=59h)
  7144. Note: does not preserve any registers other than SS:SP
  7145. ---------------------------------------------
  7146. INT 21 - DOS 3.2 internal - ???
  7147.     AH = 64h
  7148.     AL = subfunction
  7149.         00h get ???
  7150.         Return: DL = ???
  7151.         01h set ???
  7152.         DL = ???
  7153.         02h get and set ???
  7154.         DL = new ???
  7155.         Return: DL = old ???
  7156. ---------------------------------------------
  7157. INT 21 - DOS 3.3 internal - ???
  7158.     AH = 64h
  7159.     AL = flag
  7160.         00h  ??? 
  7161.         nonzero  ??? 
  7162. Return: nothing
  7163. Note: seems to have something to do with the network
  7164. ---------------------------------------------
  7165. INT 21 - DOS 3.3+ - GET EXTENDED COUNTRY INFORMATION
  7166.     AH = 65h
  7167.     AL = info ID
  7168.         01h get general internationalization info
  7169.         02h get pointer to uppercase table
  7170.         04h get pointer to filename uppercase table
  7171.         06h get pointer to collating sequence table
  7172.         07h (DOS 4.x) get pointer to Double-Byte Character Set table
  7173.     BX = code page (-1=global code page)
  7174.     DX = country ID (-1=current country)
  7175.     ES:DI -> country information buffer
  7176.     CX = size of buffer (>= 5)
  7177. Return: CF set on error
  7178.         AX = error code (see AH=59h)
  7179.     CF clear if succesful
  7180.         CX = size of country information returned
  7181.         ES:DI -> country information
  7182.  
  7183. Format of country information:
  7184. Offset    Size    Description
  7185.  00h    BYTE    info ID
  7186. ---if info ID = 01h---
  7187.  01h    WORD    size
  7188.  03h    WORD    country ID
  7189.  05h    WORD    code page
  7190.  07h 34 BYTEs    country-dependent info (see AH=38h)
  7191. ---if info ID = 02h---
  7192.  01h    DWORD    pointer to uppercase table (see below)
  7193. ---if info ID = 04h---
  7194.  01h    DWORD    pointer to collating table (see below)
  7195. ---if info ID = 06h---
  7196.  01h    DWORD    pointer to filename uppercase table (see below)
  7197. ---if info ID = 07h (DOS 4.x)---
  7198.  01h    DWORD    pointer to DBCS lead byte table (see below)
  7199.  
  7200. Format of uppercase table:
  7201. Offset    Size    Description
  7202.  00h    WORD    table size
  7203.  02h 128 BYTEs    uppercase equivalents (if any) of chars 80h to FFh
  7204.  
  7205. Format of collating table:
  7206. Offset    Size    Description
  7207.  00h    WORD    table size
  7208.  02h 256 BYTEs    values used to sort characters 00h to FFh
  7209.  
  7210. Format of filename uppercase table:
  7211. Offset    Size    Description
  7212.  00h    WORD    table size
  7213.  02h 128 BYTEs    uppercase equivalents (if any) of chars 80h to FFh
  7214.  
  7215. Format of DBCS lead byte table:
  7216. Offset    Size    Description
  7217.  00h    WORD    length
  7218.  02h 2N BYTEs    start/end for N lead byte ranges
  7219.     WORD    0000h    (end of table)
  7220. ---------------------------------------------
  7221. INT 21 - DOS 3.3+ - GET GLOBAL CODE PAGE TABLE
  7222.     AX = 6601h
  7223. Return: CF set on error
  7224.         AX = error code (see AH=59h)
  7225.     CF clear if successful
  7226.         BX = active code page
  7227.         DX = system code page
  7228. ---------------------------------------------
  7229. INT 21 - DOS 3.3+ - SET GLOBAL CODE PAGE TABLE
  7230.     AX = 6602h
  7231.     BX = active code page
  7232.         437  US
  7233.         850  Multilingual
  7234.         860  Portugal
  7235.         863  Canada (French)
  7236.         865  Norway/Denmark
  7237.     DX = system code page (active page at boot time)
  7238. Return: CF set on error
  7239.         AX = error code (see AH=59h)
  7240. ---------------------------------------------
  7241. INT 21 - DOS 3.3+ - SET HANDLE COUNT
  7242.     AH = 67h
  7243.     BX = desired number of handles (max 255)
  7244. Return: CF set if error (and error code in AX)
  7245. ---------------------------------------------
  7246. INT 21 - DOS 3.3+ - COMMIT FILE, WRITE ALL BUFFERED DATA TO DISK
  7247.     AH = 68h
  7248.     BX = file handle
  7249. Return: CF set on error 
  7250.         AX = error code (see AH=59h)
  7251. Note: if BX <= 20, no action is taken
  7252. ---------------------------------------------
  7253. INT 21 - DOS 4.0 internal - GET/SET DISK SERIAL NUMBER
  7254.     AH = 69h
  7255.     AL = subfunction
  7256.         00h    get serial number
  7257.         01h set serial number
  7258.     BL = drive (0=default, 1=A, 2=B, etc)
  7259.     DS:DX -> disk info (see below)
  7260. Return: CF set on error
  7261.         AX = error code (see AH=59h)
  7262.     CF clear if successful
  7263.         AX destroyed
  7264.         (AL = 00h) buffer filled with appropriate values from extended BPB
  7265.         (AL = 01h) extended BPB on disk set to values from buffer
  7266. Notes:    does not generate a critical error; all errors are returned in AX
  7267.     error 0005h given if no extended BPB on disk
  7268.     does not work on network drives (error 0001h)
  7269.     buffer after first two bytes is exact copy of bytes 27h thru 3Dh of
  7270.        extended BPB on disk
  7271.  
  7272. Format of disk info:
  7273. Offset    Size    Description
  7274.  00h    WORD    ??? (zero)
  7275.  02h    DWORD    disk serial number (binary)
  7276.  06h 11 BYTEs    volume label or "NO NAME    " if none present
  7277.  11h  8 BYTEs    FAT type--string "FAT12   " or "FAT16    "
  7278. ---------------------------------------------
  7279. INT 21 - DOS 4.0 internal - ???
  7280.     AH = 6Ah
  7281.     ???
  7282. Return: ???
  7283. ---------------------------------------------
  7284. INT 21 - DOS 4.0 internal - ???
  7285.     AH = 6Bh
  7286.     ???
  7287. Return: ???
  7288. ---------------------------------------------
  7289. INT 21 - DOS 4.0 - EXTENDED OPEN/CREATE
  7290.     AX = 6C00h
  7291.     BL = open mode as in AL for normal open (INT 21h/AH=3Dh)
  7292.         bits 0-2: access mode
  7293.         bit 3 reserved
  7294.         bits 4-6: sharing mode
  7295.         bit 7: inheritance
  7296.     BH = 0WF00000
  7297.         W = auto commit on write
  7298.         F = return error rather than doing INT 24h
  7299.     CX = create attribute
  7300.         bit 0: readonly
  7301.         bit 1: hidden
  7302.         bit 2: system
  7303.         bit 3: volume label
  7304.         bit 4: reserved
  7305.         bit 5: archive
  7306.         bits 6-15 reserved
  7307.     DL = action if file exists/does not exists
  7308.         bits 7-4 action if file does not exist
  7309.             0000 fail
  7310.             0001 create
  7311.         bits 3-0 action if file exists
  7312.             0000 fail
  7313.             0001 open
  7314.             0010 replace/open
  7315.     DH = 00h (reserved)
  7316.     DS:SI -> ASCIZ file name
  7317. Return: CF set on error
  7318.        AX = error code (see AH=59h)
  7319.     CF clear if successful
  7320.        AX = file handle
  7321.        CX = 1 file opened
  7322.         2 file created
  7323.         3 file replaced
  7324. ---------------------------------------------
  7325. INT 21 - ???
  7326.     AH = 89h
  7327.     ???
  7328. Note: called by Microsoft C 4.0 startup code
  7329. ---------------------------------------------
  7330. INT 21 - Novell NetWare SFT Level II - EXTENDED FILE ATTRIBUTES
  7331.     AH = B6h
  7332.     AL = subfunction
  7333.         00h get extended file attributes
  7334.         01h set extended file attributes
  7335.     CL = attributes
  7336.         bit 4: transaction tracking file
  7337.         5: indexing file (to be implemented)
  7338.         6: read audit (to be implemented)
  7339.         7: write audit (to be implemented)
  7340.     DS:DX -> ASCIZ pathname
  7341. Return: CF set on error
  7342.         AL = error code
  7343.         FFh file not found
  7344.         8Ch caller lacks privileges
  7345.     CL = current extended file attributes
  7346. ---------------------------------------------
  7347. INT 21 - Novell Advanced NetWare 2.0+ - PRINT JOBS
  7348.     AH = B8h
  7349.     AL = subfunction
  7350.         00h get default print job flags
  7351.         01h set default capture flags
  7352.         02h get specific capture flags
  7353.         03h set specific print job flags
  7354.         04h get default local printer
  7355.         05h set default local printer
  7356.         06h set capture print queue
  7357.         07h set capture print job
  7358.         08h get banner user name
  7359.         09h set banner user name
  7360.     CX = buffer size
  7361.     ES:BX -> buffer
  7362. Return: none
  7363. ---------------------------------------------
  7364. INT 21 - Novell NetWare 4.0 - SET END OF JOB STATUS
  7365.     AH = BBh
  7366.     AL = new EOJ flag
  7367.         00h disable EOJs
  7368.         otherwise enable EOJs
  7369. Return: AL = old EOJ flag
  7370. ---------------------------------------------
  7371. INT 21 - Novell NetWare 4.6 - LOG PHYSICAL RECORD
  7372.     AH = BCh
  7373.     AL = flags
  7374.         bit 0: lock as well as log record
  7375.         1: non-exclusive lock
  7376.     BX = file handle
  7377.     CX:DX = offset
  7378.     BP = timeout in timer ticks (1/18 sec)
  7379.     SI:DI = length
  7380. Return: AL = error code
  7381. ---------------------------------------------
  7382. INT 21 - Novell NetWare 4.6 - RELEASE PHYSICAL RECORD
  7383.     AH = BDh
  7384.     BX = file handle
  7385.     CX:DX = offset
  7386. Return: AL = error code
  7387. ---------------------------------------------
  7388. INT 21 - Novell NetWare 4.6 - CLEAR PHYSICAL RECORD
  7389.     AH = BEh
  7390.     BX = file handle
  7391.     CX:DX = offset
  7392. Return: AL = error code
  7393. ---------------------------------------------
  7394. INT 21 - Novell NetWare 4.6 - LOG RECORD (FCB)
  7395.     AH = BFh
  7396.     AL = flags
  7397.         bit 0: lock as well as log record
  7398.         1: non-exclusive lock
  7399.     DS:DX -> FCB
  7400.     BX:CX = offset
  7401.     BP = timeout in timer ticks (1/18 sec)
  7402.     SI:DI = length
  7403. Return: AL = error code
  7404. ---------------------------------------------
  7405. INT 21 - Novell NetWare 4.6 - RELEASE RECORD (FCB)
  7406.     AH = C0h
  7407.     DS:DX -> FCB
  7408.     BX:CX = offset
  7409. Return: AL = error code
  7410. ---------------------------------------------
  7411. INT 21 - Novell NetWare 4.6 - CLEAR RECORD (FCB)
  7412.     AH = C1h
  7413.     DS:DX -> FCB
  7414.     BX:CX = offset
  7415. Return: AL = error code
  7416. ---------------------------------------------
  7417. INT 21 - Novell NetWare 4.6 - LOCK PHYSICAL RECORD SET
  7418.     AH = C2h
  7419.     AL = flags
  7420.         bit 1: non-exclusive lock
  7421.     BP = timeout in timer ticks (1/18 sec)
  7422. Return: AL = error code
  7423. ---------------------------------------------
  7424. INT 21 - Novell NetWare 4.6 - RELEASE PHYSICAL RECORD SET
  7425.     AH = C3h
  7426. Return: AL = error code
  7427. ---------------------------------------------
  7428. INT 21 - Novell NetWare 4.6 - CLEAR PHYSICAL RECORD SET
  7429.     AH = C4h
  7430. Return: AL = error code
  7431. ---------------------------------------------
  7432. INT 21 - Novell NetWare 4.6 - SEMAPHORES
  7433.     AH = C5h
  7434.     AL = subfunction
  7435.         00h open semaphore
  7436.         DS:DX -> semaphore name
  7437.         CL = initial value
  7438.         01h examine semaphore
  7439.         Return: CX = semaphore value (sign extended)
  7440.             DL = open count
  7441.         02h wait on semaphore
  7442.         BP = timeout in timer ticks (1/18 sec)
  7443.         03h signal semaphore
  7444.         04h close semaphore
  7445.     CX:DX = semaphore handle (except function 00h)
  7446. Return: AL = error code
  7447.     if function 00h
  7448.        CX:DX = semaphore handle
  7449.        BL = open count
  7450. ---------------------------------------------
  7451. INT 21 - Novell NetWare 4.6 - GET OR SET LOCK MODE
  7452.     AH = C6h
  7453.     AL = subfunction
  7454.         00h set old "compatibility" mode
  7455.         01h set new extended locks mode 
  7456.         02h get lock mode
  7457. Return: AL = current lock mode
  7458. ---------------------------------------------
  7459. INT 21 - Novell NetWare 4.0 - TTS
  7460.     AH = C7h
  7461.     AL = subfunction
  7462.         00h begin transaction (NetWare SFT level II)
  7463.         Return: AL = error code
  7464.         01h end transaction (NetWare SFT level II)
  7465.         Return: AL = error code
  7466.             CX:DX = transaction reference number
  7467.         02h TTS available (NetWare SFT level II)
  7468.         Return: AL = completion code
  7469.                 00h TTS not available
  7470.                 01h TTS available
  7471.                 FDh TTS available but disabled
  7472.         03h abort transaction (NetWare SFT level II)
  7473.         Return: AL = error code
  7474.         04h transaction status
  7475.         05h get application thresholds
  7476.         06h set application thresholds
  7477.         07h get workstation thresholds
  7478.         08h set workstation thresholds
  7479. Return: ???
  7480. ---------------------------------------------
  7481. INT 21 - Novell NetWare 4.0 - BEGIN LOGICAL FILE LOCKING
  7482.     AH = C8h
  7483.     if function C6h lock mode 00h:
  7484.         DL = mode
  7485.         00h no wait
  7486.         01h wait
  7487.     if function C6h lock mode 01h:
  7488.         BP = timeout in timer ticks (1/18 sec)
  7489. Return: AL = error code
  7490. ---------------------------------------------
  7491. INT 21 - Novell NetWare 4.0 - END LOGICAL FILE LOCKING
  7492.     AH = C9h
  7493. Return: AL = error code
  7494. ---------------------------------------------
  7495. INT 21 - Novell NetWare 4.0 - LOG PERSONAL FILE (FCB)
  7496.     AH = CAh
  7497.     DS:DX -> FCB
  7498.     if function C6h lock mode 01h:
  7499.         AL = log and lock flag
  7500.         00h log file only
  7501.         01h lock as well as log file
  7502.         BP = timeout in timer ticks (1/18 sec)
  7503. Return: AL = error code
  7504. ---------------------------------------------
  7505. INT 21 - Novell NetWare 4.0 - LOCK FILE SET
  7506.     AH = CBh
  7507.     if function C6h lock mode 00h:
  7508.         DL = mode
  7509.         00h no wait
  7510.         01h wait
  7511.     if function C6h lock mode 01h:
  7512.         BP = timeout in timer ticks (1/18 sec)
  7513. Return: AL = error code
  7514. ---------------------------------------------
  7515. INT 21 - Novell NetWare 4.0 - RELEASE FILE (FCB)
  7516.     AH = CCh
  7517.     DS:DX -> FCB
  7518. Return: none
  7519. ---------------------------------------------
  7520. INT 21 - Novell NetWare 4.0 - RELEASE FILE SET
  7521.     AH = CDh
  7522. Return: none
  7523. ---------------------------------------------
  7524. INT 21 - Novell NetWare 4.0 - CLEAR FILE (FCB)
  7525.     AH = CEh
  7526.     DS:DX -> FCB
  7527. Return: AL = error code
  7528. ---------------------------------------------
  7529. INT 21 - Novell NetWare 4.0 - CLEAR FILE SET
  7530.     AH = CFh
  7531. Return: AL = 00h
  7532. ---------------------------------------------
  7533. INT 21 - Novell NetWare 4.6 - LOG LOGICAL RECORD
  7534.     AH = D0h
  7535.     DS:DX -> record string
  7536.     if function C6h lock mode 01h:
  7537.         AL = flags
  7538.         bit 0: lock as well as log the record
  7539.         bit 1: non-exclusive lock
  7540.         BP = timeout in timer ticks (1/18 sec)
  7541. Return: AL = error code
  7542. ---------------------------------------------
  7543. INT 21 - Novell NetWare 4.6 - LOCK LOGICAL RECORD SET
  7544.     AH = D1h
  7545.     if function C6h lock mode 00h:
  7546.         DL = mode
  7547.         00h no wait
  7548.         01h wait
  7549.     if function C6h lock mode 01h:
  7550.        BP = timeout in timer ticks (1/18 sec)
  7551. Return: AL = error code
  7552. ---------------------------------------------
  7553. INT 21 - Novell NetWare 4.0 - RELEASE LOGICAL RECORD
  7554.     AH = D2h
  7555.     DS:DX -> record string
  7556. Return: AL = error code
  7557. ---------------------------------------------
  7558. INT 21 - Novell NetWare 4.0 - RELEASE LOGICAL RECORD SET
  7559.     AH = D3h
  7560. Return: AL = error code
  7561. ---------------------------------------------
  7562. INT 21 - Novell NetWare 4.0 - CLEAR LOGICAL RECORD
  7563.     AH = D4h
  7564.     DS:DX -> record string
  7565. Return: AL = error code
  7566. ---------------------------------------------
  7567. INT 21 - Novell NetWare 4.0 - CLEAR LOGICAL RECORD SET
  7568.     AH = D5h
  7569. Return: AL = error code
  7570. ---------------------------------------------
  7571. INT 21 - Novell NetWare 4.0 - END OF JOB
  7572.     AH = D6h
  7573. Return: AL = error code
  7574. ---------------------------------------------
  7575. INT 21 - Novell NetWare 4.0 - SYSTEM LOGOUT
  7576.     AH = D7h
  7577. Return: AL = error code
  7578. ---------------------------------------------
  7579. INT 21 - Novell NetWare 4.0 - GET VOLUME STATISTICS
  7580.     AH = DAh
  7581.     DL = volume number
  7582.     ES:DI -> reply buffer (see below)
  7583. Return: AL = 00h
  7584.  
  7585. Format of reply buffer:
  7586. Offset    Size    Description
  7587.  00h    WORD    sectors/block
  7588.  02h    WORD    total blocks
  7589.  04h    WORD    unused blocks
  7590.  06h    WORD    total directory entries
  7591.  08h    WORD    unused directory entries
  7592.  0Ah 16 BYTEs    volume name, null padded
  7593.  1Ah    WORD    removable flag, 0000h = not removable
  7594. ---------------------------------------------
  7595. INT 21 - Novell NetWare 4.0 - GET NUMBER OF LOCAL DRIVES
  7596.     AH = DBh
  7597. Return: AL = number of local disks
  7598. ---------------------------------------------
  7599. INT 21 - Novell NetWare 4.0 - GET STATION NUMBER
  7600.     AH = DCh
  7601. Return: AL = station number
  7602.         00h if NetWare not loaded or this machine is a non-dedicated server
  7603.     CX = station number in ASCII
  7604. ---------------------------------------------
  7605. INT 21 - Novell NetWare 4.0 - SET ERROR MODE
  7606.     AH = DDh
  7607.     DL = error mode
  7608.         00h display critical I/O errors
  7609.         01h extended errors for all I/O in AL
  7610.         02h extended errors for critical I/O in AL
  7611. Return: AL = previous error mode
  7612. ---------------------------------------------
  7613. INT 21 - Novell NetWare 4.0 - SET BROADCAST MODE
  7614.     AH = DEh
  7615.     AL = broadcast mode
  7616.         00h receive console and workstation broadcasts
  7617.         01h receive console broadcasts only
  7618.         02h receive no broadcasts
  7619.         03h store all broadcasts for retrieval
  7620.         04h get broadcast mode
  7621.         05h disable shell tiemr interrupt checks
  7622.         06h enable shell timer interrupt checks
  7623. Return: AL = old broadcast mode
  7624. ---------------------------------------------
  7625. INT 21 - Novell NetWare 4.0 - CAPTURE
  7626.     AH = DFh
  7627.     AL = subfunction
  7628.         00h start LPT capture
  7629.         01h end LPT capture
  7630.         02h cancel LPT capture
  7631.         03h flush LPT capture
  7632.         04h start specific capture
  7633.         05h end specific capture
  7634.         06h cancel specific capture
  7635.         07h flush specific capture
  7636. Return: AL = error code
  7637. ---------------------------------------------
  7638. INT 21 - Novell NetWare 4.0 - PRINT SPOOLING
  7639.     AH = E0h
  7640.     DS:SI -> request buffer
  7641.     ES:DI -> reply buffer
  7642.     subfunction in third byte of request buffer
  7643.         00h spool data to a capture file
  7644.         01h close and queue capture file
  7645.         02h set spool flags
  7646.         03h spool existing file
  7647.         04h get spool queue entry
  7648.         05h remove entry from spool queue
  7649.         06h get printer status
  7650.         09h create a disk capture file
  7651. Return: AL = error code
  7652. ---------------------------------------------
  7653. INT 21 - Novell NetWare 4.0 - BROADCAST MESSAGES
  7654.     AH = E1h
  7655.     DS:SI -> request buffer
  7656.     ES:DI -> reply buffer
  7657.     subfunction in third byte of request buffer
  7658.         00h send broadcast message
  7659.         01h get broadcase message
  7660.         02h disable station broadcasts
  7661.         03h enable station broadcasts
  7662.         04h send personal message
  7663.         05h get personal message
  7664.         06h open message pipe
  7665.         07h close message pipe
  7666.         08h check pipe status
  7667.         09h broadcast to console
  7668. Return: AL = error code
  7669. ---------------------------------------------
  7670. INT 21 - Novell NetWare 4.0 - DIRECTORY FUNCTIONS
  7671.     AH = E2h
  7672.     DS:SI -> request buffer
  7673.     ES:DI -> reply buffer
  7674.     subfunction in third byte of request buffer
  7675.         00h set directory handle
  7676.         01h get directory path
  7677.         02h scan directory information
  7678.         03h get effective directory rights
  7679.         04h modify maximum rights mask
  7680.         05h get volume number
  7681.         06h get volume name
  7682.         0Ah create directory
  7683.         0Bh delete directory
  7684.         0Ch scan directory for trustees
  7685.         0Dh add trustee to directory
  7686.         0Eh delete trustee from directory
  7687.         0Fh rename directory
  7688.         10h purge erased files
  7689.         11h restore erased file
  7690.         12h allocate permanent directory handle
  7691.         13h allocate temporary directory handle
  7692.         14h deallocate directory handle
  7693.         15h get volume info with handle
  7694.         16h allocate special temporary directory handle
  7695.         17h retrieve a short base handle (Advanced NetWare 2.0)
  7696.         18h restore a short base handle (Advanced NetWare 2.0)
  7697.         19h set directory information
  7698. Return: AL = error code
  7699. ---------------------------------------------
  7700. INT 21 - Novell NetWare 4.0 - CONNECTION CONTROL
  7701.     AH = E3h
  7702.     DS:SI -> requst buffer
  7703.     ES:DI -> reply buffer
  7704.     subfunction in third byte of request buffer
  7705.         00h login
  7706.         01h change password
  7707.         02h map user to station set
  7708.         03h map object to number
  7709.         04h map number to object
  7710.         05h get station's logged information
  7711.         06h get station's root mask (obsolete)
  7712.         07h map group name to number
  7713.         08h map number to group name
  7714.         09h get memberset M of group G
  7715.         0Ah enter login area
  7716.         0Bh ???
  7717.         0Ch ???
  7718.         0Dh log network message
  7719.         0Eh get disk utilization (Advanced NetWare 1.0)
  7720.         0Fh scan file information (Advanced NetWare 1.0)
  7721.         10h set file information (Advanced NetWare 1.0)
  7722.         11h get file server information (Advanced NetWare 1.0)
  7723.         12h ???
  7724.         13h get internet address (Advanced NetWare 1.02)
  7725.         14h login to file server (Advanced NetWare 2.0)
  7726.         15h get object connection numbers (Advanced NetWare 2.0)
  7727.         16h get connection information (Advanced NetWare 1.0)
  7728.         32h create object (Advanced NetWare 1.0)
  7729.         33h delete object (Advanced NetWare 1.0)
  7730.         34h rename object (Advanced NetWare 1.0)
  7731.         35h get object ID (Advanced NetWare 1.0)
  7732.         36h get object name (Advanced NetWare 1.0)
  7733.         37h scan object (Advanced NetWare 1.0)
  7734.         38h change object security (Advanced NetWare 1.0)
  7735.         39h create propery (Advanced NetWare 1.0)
  7736.         3Ah delete property (Advanced NetWare 1.0)
  7737.         3Bh change property security (Advanced NetWare 1.0)
  7738.         3Ch scan property (Advanced NetWare 1.0)
  7739.         3Dh read property value (Advanced NetWare 1.0)
  7740.         3Eh write property value (Advanced NetWare 1.0)
  7741.         3Fh verify object password (Advanced NetWare 1.0)
  7742.         40h change object password (Advanced NetWare 1.0)
  7743.         41h add object to set (Advanced NetWare 1.0)
  7744.         42h delete object from set (Advanced NetWare 1.0)
  7745.         43h is object in set? (Advanced NetWare 1.0)
  7746.         44h close bindery (Advanced NetWare 1.0)
  7747.         45h open bindery (Advanced NetWare 1.0)
  7748.         46h get bindery access level (Advanced NetWare 1.0)
  7749.         47h scan object trustee paths (Advanced NetWare 1.0)
  7750.         C8h check console priviledges
  7751.         C9h get file server description strings
  7752.         CAh set file server date and time
  7753.         CBh disable file server login
  7754.         CCh enable file server login
  7755.         CDh get file server login status
  7756.         CEh purge all erased files
  7757.         CFh disable transaction tracking
  7758.         D0h enable transaction tracking
  7759.         D1h send console broadcast
  7760.         D2h clear connection number
  7761.         D3h down file server
  7762.         D4h get file system statistics
  7763.         D5h get transaction tracking statistics
  7764.         D6h read disk cache statistics
  7765.         D7h get drive mapping table
  7766.         D8h read physical disk statistics
  7767.         D9h get disk channel statistics
  7768.         DAh get connection's task information
  7769.         DBh get list of connection's open files
  7770.         DCh get list of connections using a file
  7771.         DDh get physical record locks by connection and file
  7772.         DEh get physical record locks by file
  7773.         DFh get logical records by connection
  7774.         E0h get logical record information
  7775.         E1h get connection's semaphores
  7776.         E2h get semaphore information
  7777.         E3h get LAN driver's configuration information
  7778.         E5h get connection's usage statistics
  7779.         E6h get object's remaining disk space
  7780.         E7h get server LAN I/O statistics
  7781.         E8h get server miscellaneous information
  7782.         E9h get volume information
  7783. Return: AL = error code
  7784. ---------------------------------------------
  7785. INT 21 - Novell NetWare 4.0 - SET FILE ATTRIBUTES (FCB)
  7786.     AH = E4h
  7787.     CL = file attributes
  7788.         bit 0: read only
  7789.         1: hidden
  7790.         2: system
  7791.         7: shareable
  7792.     DX:DX -> FCB
  7793. Return: AL = error code
  7794. ---------------------------------------------
  7795. INT 21 - DoubleDos - INSTALLATION CHECK
  7796.     AX = E400h
  7797. Return: AL <> 00h if DoubleDos is active
  7798. ---------------------------------------------
  7799. INT 21 - Novell NetWare 4.0 - UPDATE FILE SIZE (FCB)
  7800.     AH = E5h
  7801.     DS:DX -> FCB
  7802. Return: AL = error code
  7803. ---------------------------------------------
  7804. INT 21 - Novell NetWare 4.0 - COPY FILE TO FILE (FCB)
  7805.     AH = E6h
  7806.     CX:DX = number of bytes to copy
  7807.     DS:SI -> source FCB
  7808.     ES:DI -> destination FCB
  7809. Return: AL = error code
  7810. ---------------------------------------------
  7811. INT 21 - Novell NetWare 4.0 - GET FILE SERVER DATE AND TIME
  7812.     AH = E7h
  7813.     DS:DX -> reply buffer
  7814.         BYTE  year - 1900
  7815.         BYTE  month
  7816.         BYTE  day
  7817.         BYTE  hours
  7818.         BYTE  minutes
  7819.         BYTE  seconds
  7820.         BYTE  day of week (0 = Sunday)
  7821. Return: AL = error code
  7822. ---------------------------------------------
  7823. INT 21 - Novell NetWare 4.6 - SET FCB RE-OPEN MODE
  7824.     AH = E8h
  7825.     DL = mode
  7826.         00h no automatic re-open
  7827.         01h auto re-open
  7828. Return: AL = error code
  7829. ---------------------------------------------
  7830. INT 21 - Novell NetWare 4.6 - SHELL'S "GET BASE STATUS"
  7831.     AH = E9h
  7832.     AL = subfunction
  7833.         00h get directory handle
  7834.     DX = drive number to check (0 = A:)
  7835. Return: AL = network pathbase
  7836.     AH = base flags
  7837.         00h drive not currently mapped to a base
  7838.         01h drive is mapped to a permanent base
  7839.         02h drive is mapped to a temporary base
  7840.         03h drive exists locally
  7841. ---------------------------------------------
  7842. INT 21 - Novell NetWare 4.6 - RETURN SHELL VERSION
  7843.     AH = EAh
  7844.     AL = subfunction
  7845.         00h return code in AL
  7846.         Return: AL = hardware type
  7847.                 00h IBM PC
  7848.                 01h Victor 9000
  7849.         01h get workstation environment string
  7850.         ES:DI -> 40-byte buffer
  7851.         Return: buffer filled with three null-terminated entries:
  7852.             major operating system
  7853.             version
  7854.             hardware type
  7855. Return: AH = 00h if DOS
  7856. ---------------------------------------------
  7857. INT 21 - DoubleDos - TURN OFF TASK SWITCHING
  7858.     AH = EAh
  7859. Return: task switching turned off
  7860. ---------------------------------------------
  7861. INT 21 - Novell NetWare 4.6 - LOG FILE
  7862.     AH = EBh
  7863.     DS:DX -> ASCIZ filename
  7864.     if function C6h lock mode 01h:
  7865.         AL = flags
  7866.         00h log file only
  7867.         01h lock as well as log file
  7868.         BP = timeout in timer ticks (1/18 second)
  7869. Return: AL = error code
  7870. ---------------------------------------------
  7871. INT 21 - DoubleDos - TURN ON TASK SWITCHING
  7872.     AH = EBh
  7873. Return: task switching turned on
  7874. ---------------------------------------------
  7875. INT 21 - Novell NetWare 4.6 - RELEASE FILE
  7876.     AH = ECh
  7877.     DS:DX -> ASCIZ filename
  7878. Return: none
  7879. ---------------------------------------------
  7880. INT 21 - DoubleDos - GET VIRTUAL SCREEN ADDRESS
  7881.     AH = ECh
  7882. Return: ES = segment of virtual screen
  7883. Note:    screen address can change if task-switching is on!!
  7884. ---------------------------------------------
  7885. INT 21 - Novell NetWare - CLEAR FILE
  7886.     AH = EDh
  7887.     DS:DX -> ASCIZ filename
  7888. Return: AL = error code
  7889. ---------------------------------------------
  7890. INT 21 - Novell NetWare 4.6 - GET PHYSICAL STATION NUMBER
  7891.     AH = EEh
  7892. Return: CX:BX:AX = six-byte address
  7893. ---------------------------------------------
  7894. INT 21 - DoubleDos - GIVE AWAY TIME TO OTHER TASKS
  7895.     AH = EEh
  7896.     AL = number of 55ms time slices to give away
  7897. Return: returns after giving away time slices
  7898. ---------------------------------------------
  7899. INT 21 - Novell Advanced NetWare 1.0+ - GET DRIVE INFO
  7900.     AH = EFh
  7901.     AL = subfunction
  7902.         00h get drive handle table
  7903.         01h get drive flag table
  7904.         02h get drive connection ID table
  7905.         03h get connection ID table
  7906.         04h get file server name table
  7907. Return: ES:DI -> shell status table
  7908. ---------------------------------------------
  7909. INT 21 - Novell Advanced NetWare 1.0+ - CONNECTION ID
  7910.     AH = F0h
  7911.     AL = subfunction
  7912.         00h set preferred connection ID
  7913.         01h get preferred connection ID
  7914.         02h get default connection ID
  7915.         03h LPT capture active
  7916.         04h set primary connection ID
  7917.         05h get primary connection ID
  7918.     DL = preferred file server
  7919. Return: AL = selected file server
  7920. ---------------------------------------------
  7921. INT 21 - Novell Advanced NetWare 1.0+ - FILE SERVER CONNECTION
  7922.     AH = F1h
  7923.     AL = subfunction
  7924.         00h attach to file server
  7925.         DL = preferred file server
  7926.         01h detach from file server
  7927.         02h logout from file server
  7928. Return: AL = completion code
  7929. ---------------------------------------------
  7930. INT 21 - Novell NetWare - ???
  7931.     AH = F2h
  7932.     ???
  7933. Return: ???
  7934. ---------------------------------------------
  7935. INT 21 - Novell Advanced NetWare 2.0+ - FILE SERVER FILE COPY
  7936.     AH = F3h
  7937.     ES:DI -> request string (see below)
  7938. Return: AL = status/error code
  7939.     CX:DX = number of bytes copied
  7940.  
  7941. Format of request string:
  7942. Offset    Size    Description
  7943.  00h    WORD    source file handle
  7944.  02h    WORD    destination file handle
  7945.  04h    DWORD    starting offset in source
  7946.  08h    DWORD    starting offset in destination
  7947.  0Ch    DWORD    number of bytes to copy
  7948. ---------------------------------------------
  7949. INT 21 - CED - INSTALLABLE COMMANDS
  7950.     AH = FFh
  7951.     AL = 00h add installable command
  7952.            BL = mode - bit 0 = 1 callable from DOS prompt
  7953.                bit 1 = 1 callable from application
  7954.            DS:SI -> CR-terminated command name
  7955.            ES:DI -> FAR routine entry point
  7956.     AL = 01h remove installable command
  7957.            DS:SI -> CR-terminated command name
  7958.     AL = 02h reserved, may be used to test for CED installation
  7959. Return: CF set on error
  7960.         AX = 01h invalid function
  7961.          02h command not found (subfunction 01h only)
  7962.          08h insufficient memory (subfunction 00h only)
  7963.          0Eh bad data (subfunction 00h only)
  7964.     AH = 0FFh if CED not installed
  7965. ---------------------------------------------
  7966. INT 22 - DOS - TERMINATE ADDRESS
  7967.    FAR (DWORD) address of routine to be executed when program "returns to DOS".
  7968.    Should NEVER be called directly.
  7969. ---------------------------------------------
  7970. INT 23 - DOS - CONTROL "C" EXIT ADDRESS
  7971.    Automatically called from keyboard scanner when CTRL-C or CTRL-BREAK is
  7972.    detected. Normally aborts program and returns to DOS, but may be changed.
  7973. ---------------------------------------------
  7974. INT 24 - DOS - FATAL ERROR HANDLER ADDRESS
  7975.    Automatically called upon detection of unrecoverable I/O error.
  7976.    Normally points to routine in resident part of COMMAND.COM that prints
  7977.    "Abort, Retry, Ignore?" message and takes the reply, but may be overridden
  7978.    if desired.
  7979.  
  7980. Provides the following values in registers on entry to interrupt handler:
  7981.     AH: bit 7 = 0 disk I/O error
  7982.           = 1 other error -- if block device, bad FAT
  7983.                   -- if char device, code in DI
  7984.         bit 6  unused
  7985.         bit 5 = 1 if Ignore allowed, 0 if not (DOS 3+)
  7986.         bit 4 = 1 if Retry allowed, 0 if not (DOS 3+)
  7987.         bit 3 = 1 if Fail allowed, 0 if not (DOS 3+)
  7988.         bit 2 \ disk area of error    00 = DOS area  01 = FAT
  7989.         bit 1 /            10 = root dir  11 = data area
  7990.         bit 0 = 1 if write, 0 if read
  7991.     AL = drive number if AH bit 7 = 1, otherwise undefined
  7992.     BP:SI -> header of device driver for which error occurred
  7993.         block device if high bit of BP:[SI+4] set
  7994.     low byte of DI:
  7995.        00h write-protect error
  7996.        01h unknown unit
  7997.        02h drive not ready
  7998.        03h unknown command
  7999.        04h data error (bad CRC)
  8000.        05h bad request structure length
  8001.        06h seek error
  8002.        07h unknown media type
  8003.        08h sector not found
  8004.        09h printer out of paper
  8005.        0Ah write fault
  8006.        0Bh read fault
  8007.        0Ch general failure
  8008.        0Dh (DOS 3+) sharing violation
  8009.        0Eh (DOS 3+) lock violation
  8010.        0Fh (DOS 3+) invalid disk change
  8011.        10h (DOS 3+) FCB unavailable
  8012.        11h (DOS 3+) sharing buffer overflow
  8013. Handler must return
  8014.     AL = 00h ignore error
  8015.        = 01h retry operation
  8016.        = 02h terminate program through INT 22h
  8017.        = 03h fail system call in progress (DOS 3+)
  8018. ---------------------------------------------
  8019. INT 25 - DOS - ABSOLUTE DISK READ (except DOS 4.0/COMPAQ DOS 3.31 >32M partitn)
  8020.     AL = drive number (0=A, 1=B, etc)
  8021.     DS:BX = Disk Transfer Address (buffer)
  8022.     CX = number of sectors to read
  8023.     DX = first relative sector to read
  8024. Return: CF set on error
  8025.         AL = error code issued to INT 24h in low half of DI
  8026.         AH = 80h if attachment failed to respond
  8027.          40h if seek operation failed
  8028.          20h if controller failed
  8029.          10h if data error (bad CRC)
  8030.          08h if DMA failure
  8031.          04h if requested sector not found
  8032.          03h if write-protected disk
  8033.          02h if bad address mark
  8034.          01h if bad command
  8035. Note: ORIGINAL FLAGS ON STACK!    May destroy all registers except segment regs
  8036. BUG:    DOS 3.1 through 3.3 set the word at ES:[BP+1Eh] to FFFFh if AL is an
  8037.     invalid drive number
  8038. ---------------------------------------------
  8039. INT 25 - DOS 4.0/COMPAQ DOS 3.31 - ABSOLUTE DISK READ (>32M hard-disk partitn)
  8040.     AL = drive number (0=A, 1=B, etc)
  8041.     CX = FFFFh
  8042.     DS:BX -> disk read packet (see below)
  8043. Return: same as above???
  8044. Note: partition is potentially >32M (and requires this form of the call) if
  8045.       bit 1 of device attribute word in device driver is set
  8046.  
  8047. Format of disk read packet:
  8048. Offset    Size    Description
  8049.  00h    DWORD    sector number
  8050.  04h    WORD    number of sectors to read
  8051.  06h    DWORD    transfer address
  8052. ---------------------------------------------
  8053. INT 26 - DOS - ABSOLUTE DISK WRITE (except DOS 4.0/COMPAQ DOS 3.31 >32M partn)
  8054.     AL = drive number (0=A, 1=B, etc)
  8055.     DS:BX = Disk Transfer Address (buffer)
  8056.     CX = number of sectors to write
  8057.     DX = first relative sector to write
  8058. Return: CF set on error
  8059.         AL = error code issued to INT 24h in low half of DI
  8060.         AH = same error codes as for INT 25h
  8061. Note:    ORIGINAL FLAGS ON STACK!
  8062. BUG:    DOS 3.1 through 3.3 set the word at ES:[BP+1Eh] to FFFFh if AL is an
  8063.     invalid drive number
  8064. ---------------------------------------------
  8065. INT 26 - DOS 4.0/COMPAQ DOS 3.31 - ABSOLUTE DISK WRITE (>32M hard-disk partitn)
  8066.     AL = drive number (0=A, 1=B, etc)
  8067.     CX = FFFFh
  8068.     DS:BX -> disk write packet (see below)
  8069. Return: same as above???
  8070. Note: partition is potentially >32M (and requires this form of the call) if
  8071.       bit 1 of device attribute word in device driver is set
  8072.  
  8073. Format of disk write packet:
  8074. Offset    Size    Description
  8075.  00h    DWORD    sector number
  8076.  04h    WORD    number of sectors to read
  8077.  06h    DWORD    transfer address
  8078. ---------------------------------------------
  8079. INT 27 - DOS - TERMINATE BUT STAY RESIDENT
  8080.     CS = current program segment
  8081.     DX = last program byte + 1
  8082. Return: never
  8083. ---------------------------------------------
  8084.